I'm debugging a protractor solution in visual studio code. How I can do to pass the baseUrl as parameter in launch.json file?
This is my protractor.conf.js file
exports.config = {
seleniumAddress: 'http://localhost:4444/wd/hub',
//baseUrl: 'xxx',
...
};
This is my launch.json file:
{
"version": "0.1.0",
"configurations": [
{
"name": "Launch e2e Tests",
"type": "node",
"program": "node_modules/protractor/lib/cli.js",
"stopOnEntry": false,
"args": ["protractor.conf.js","--baseUrl='pippo'" ],
"cwd": ".",
"runtimeExecutable": null,
"isShellCommand": true,
"runtimeArgs": [],
"env": { },
"sourceMaps": false,
"outDir": null
}
]
}
I use the default launch.json
and alter just these two settings:
"program": "c:/Users/lee/AppData/Roaming/npm/node_modules/protractor/bin/protractor",
"args": ["${workspaceRoot}/protractor.conf.js"],
Try setting the runtime executable:
"runtimeExecutable": "node_modules/protractor/bin/protractor",
"args": ["--baseUrl=https://127.0.0.1"]
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With