I need to launch a url for UI testing in a KarateDSL scenario.
I have configured, in Feature -> Background:
* configure driver = { type: 'chrome', executable: 'chromesh' }
Where, chromesh is a executable (chromium-browser launching) bash script in ~/.local/bin.
At run it always seems to be using the default driver config:
18:38:09.781 [null_1552396089768] ERROR c.intuit.karate.shell.CommandThread - command error: [/Applications/Google Chrome.app/Contents/MacOS/Google Chrome, --remote-debugging-port=9222, --no-first-run, --user-data-dir=/home/../target/null_1552396089768, --headless] - Cannot run program "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome" (in directory "target/null_1552396089768"): error=2, No such file or directory
Karate version: 0.9.1
Is there any configuration I'm missing or done wrong?
Thanks.
Are you using IntelliJ - there's this known problem where it does not honor the system environmental variables in some situations.
Try running your test from the command line via maven, e.g.
mvn test -Dtest=MyJunitRunner
Related
I am using deno for the first time and The system cannot find the path specified. (os error 3) is the error I am getting. My code below:-
import { Application } from 'https://deno.land/x/oak/mod.ts'
const app = new Application();
const port = 3000;
app.use((ctx) => {
ctx.response.body = "Hello World"
})
app.listen({ port })
console.log(`localhost:${port}`)
I am using deno run --allow-net .\server.js on powershell to start deno. Any help would be appreciated.
EDIT: If I try to do a simple console.log and run the file with deno run server.js it runs fine which mean that the deno environment is setup correctly. As soon as I add the import statement at the top, the error starts happening.
The issue might be that you have a cached version of oak for an old version of deno.
do:
deno cache --reload server.js
And then run your server again:
deno run --allow-net server.js
It is considered a bad practice to use non-versioned URL, but in this case since there's no new version released yet for deno 1.0.3 you don't have a choice but to use master.
UPDATE: The error might be fixed by PR #6000
I got the same error. After some tries, I see that there is different betwwen nodejs and deno when use import. In node, we use this
import { Server } from './Server';
But in deno we use
import { Server } from './Server/index.js
It resolved my issue, hope is the same for you
I also got the same error. I did the following steps to resolve this error:
If you have Visual Studio open, first close it.
Open your command(cmd) prompt Run as Administrator
Run this command scoop install deno
Now open Visual Studio Code and Run Your Program using this command:
deno run --allow-net --allow-read --allow-write ./server.js
or
deno run --allow-net --allow-read --allow-write .\server.js
I'm trying to restore an a Xen VM (domain) from state file which I create previously. At the restore I need to modify the XML of this VM with the following command:
virsh restore domU.state --xml newconfig.xml
This command triggers an error with the following text:
error: Failed to restore domain from domU.state
error: argument unsupported: xml modification unsupported
What I already try:
restore without XML, which works perfectly.
run the command with the original xml the domain was created from
run the command with a totally different file which is not even an XML
At step 2. & 3. the error output was always the same.
Used versions:
xen 4.11.1
libvirt 5.1.0
os fedora 30
As the error message suggests, the ability to pass in custom XML when restoring a guest from a snapshot, is unfortunately not supported by the libvirt Xen (libxl) driver. This feature only works with QEMU/KVM at this time.
On Linux, the RSelenium/Selenium seems to be behaving erratically. I start the server manually and it seems to start up fine. Sometimes I am able to connect to it from my R session and other times I get an error. I cannot yet pinpoint the cause: the same script seems to work sometimes and not other times. Any ideas?
Here is the output from starting the server:
12:41:25.811 INFO - Launching a standalone server
12:41:26.102 INFO - Java: Sun Microsystems Inc. 11.0-b16
12:41:26.102 INFO - OS: Linux 2.6.32-431.17.1.el6.x86_64 amd64
12:41:26.157 INFO - v2.44.0, with Core v2.44.0. Built from revision 76d78cf
12:41:26.492 INFO - Default driver org.openqa.selenium.ie.InternetExplorerDriver registration is skipped: registration capabilities Capabilities [{platform=WINDOWS, ensureCleanSession=true, browserName=internet explorer, version=}] does not match with current platform: LINUX
12:41:26.589 INFO - RemoteWebDriver instances should connect to: http://127.0.0.1:4444/wd/hub
12:41:26.589 INFO - Version Jetty/5.1.x
12:41:26.590 INFO - Started HttpContext[/selenium-server/driver,/selenium-server/driver]
12:41:26.590 INFO - Started HttpContext[/selenium-server,/selenium-server]
12:41:26.590 INFO - Started HttpContext[/,/]
12:41:36.597 INFO - Started org.openqa.jetty.jetty.servlet.ServletHandler#2993a66f
12:41:36.598 INFO - Started HttpContext[/wd,/wd]
12:41:36.601 INFO - Started SocketListener on 0.0.0.0:4444
12:41:36.601 INFO - Started org.openqa.jetty.jetty.Server#6f507fb2
The error I receive in my R session:
Couldnt connect to host on http://localhost:4444/wd/hub.
Please ensure a Selenium server is running.Error in queryRD(paste0(serverURL, "/session"), "POST", qdata = toJSON(serverOpts))
Other times, running the exact same script everything proceeds successfully. It could be a difference of what computer node actually executes the script but I cannot tell what the problem is when it will not connect.
library(RCurl)
library(RJSONIO)
library(XML)
# running selenium
system("java -jar selenium-server-standalone-2.44.0.jar")
I faced same issue and try to run above code. Finally know that there only support 1.7 but not 1.8 as time being. You might try to download jre7 and jdk7.
I faced the same error in Mac, but I noticed that due to security settings the system does not let me to run the file with that piece of code. I downloaded the selenium standalone file and using control key I single-clicked the file and then from the menu I chose the open. Then the problem get solved.
I was trying to launch the Play Framework 2.3.4 server on Windows 8 with avtivator start or sbt start, and run into following errors:
The input line is too long.
The syntax of the command is incorrect.
Because of the long CLASSPATH. But event with the newly created app I run into an error:
Bad application path: -Dhttp.port=9000
The first problem can be solved by adding following lines to the build.sbt:
import com.typesafe.sbt.packager.Keys._
scriptClasspath := Seq("*")
The second problem is a currently unresolved bug in sbt-native-packager for Windows. The workaround for me was to use sbt stage and then launch directly the generated bat file at
\target\universal\stage\bin\
well, I had the same problem about
Bad application path: -Dhttp.port=9009
So the way I solve it is by editing the Bat file. I manually add all the configuration parameters into the APP_MAIN_CLASS and before the "play.core.server.NettyServer"
something like:
set "APP_MAIN_CLASS= -DapplyEvolutions.default=true -Dhttp.port=9009 play.core.server.NettyServer"
On the console.. I get the following -
Usage: java [-options] class [args...]
(to execute a class)
or java [-jar] [-options] jarfile [args...]
(to execute a jar file)
where options include:
-cp -classpath <directories and zip/jar files separated by ;>
set search path for application classes and resources
-D<name>=<value>
set a system property
-verbose[:class|gc|jni]
enable verbose output
-version print product version
-version:<value>
require the specified version to run
-showversion print product version and continue
-jre-restrict-search | -no-jre-restrict-search
include/exclude user private JREs in the version search
-agentlib:<libname>[=<options>]
load native agent library <libname>, e.g. -agentlib:hprof
see also, -agentlib:jdwp=help and -agentlib:hprof=help
-agentpath:<pathname>[=<options>]
load native agent library by full pathname
-javaagent:<jarpath>[=<options>]
load Java programming language agent, see java.lang.instrument
-? -help print this help message
-X print help on non-standard options
-splash:<imagepath> show splash screen with specified image
-ea[:<packagename>...|:<classname>]
-enableassertions[:<packagename>...|:<classname>]
enable assertions
-da[:<packagename>...|:<classname>]
-disableassertions[:<packagename>...|:<classname>]
disable assertions
-esa | -enablesystemassertions
enable system assertions
-dsa | -disablesystemassertions
disable system assertions
Eventually the server doesn't start and gets stopped after time-out. The Server was working fine. However, I wanted to restart it. I stopped the server completely and tried starting it. Since then I am facing this issue.
You can check the script that is getting executed when you right click and start the server.
Check if there are any unwanted entries in the java options which does not confirm to the java command line.