简体   繁体   English

如何从浏览器的控制台运行量角器配置文件

[英]How to run protractor config file from browser's console

I would like to know how can we run a file from the browser' console. 我想知道我们如何从浏览器的控制台运行文件。 I have to run the protractor config file that we usually run from the terminal with the command 我必须使用以下命令运行通常从终端运行的量角器配置文件

   ~  protractor config.js

I don't know about how to do this, but if you goal is to run the tests from the browser you ran that command in, my understanding is it won't work. 我不知道如何执行此操作,但是如果您的目标是从运行该命令的浏览器中运行测试,那么我的理解是它将行不通。 Protractor will use selenium to spin up a new browser, and it can't grab any currently running if I remember correctly. 量角器将使用硒启动一个新的浏览器,如果我没记错的话,它无法捕获任何当前正在运行的浏览器。

From the Chrome console in particular, I'm not sure if you have access to run other programs: 特别是从Chrome控制台,我不确定您是否有权运行其他程序:

https://developer.chrome.com/devtools/docs/console https://developer.chrome.com/devtools/docs/console

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM