when ever we run:
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
CucumberKW.runFeatureFileWithTags(featureFileFolder, (([finalTag]) as String[]))
we are using cucumber jar wrapped inside katalon Studio testing framework.
running from jenkins as part of docker image, sometimes it's causing
Keyword runFeatureFileWithTags was failed (Root cause: java.lang.StackOverflowError
at cucumber.runtime.io.FileResourceIterator$FileIterator.next(FileResourceIterator.java:73)
at cucumber.runtime.io.FlatteningIterator.moveToNext(FlatteningIterator.java:29)
at cucumber.runtime.io.FlatteningIterator.moveToNext(FlatteningIterator.java:27)
at cucumber.runtime.io.FlatteningIterator.moveToNext(FlatteningIterator.java:27)
at cucumber.runtime.io.FlatteningIterator.moveToNext(FlatteningIterator.java:27)
at cucumber.runtime.io.FlatteningIterator.moveToNext(FlatteningIterator.java:27)
at cucumber.runtime.io.FlatteningIterator.moveToNext(FlatteningIterator.java:32)
and the tests are not being executed because of this.
Not sure what is the root cause for this. Any insight or help is much appreciated
Related
I UI tesrting with maestro UI test automation tools for flutter app but after run test this error occureated
i#is-MacBook-Pro samples % maestro test android-flow.yaml
Exception in thread "main" java.lang.NoSuchMethodError: java.io.InputStream.readAllBytes()[B
at maestro.cli.device.ios.Simctl.list(Simctl.kt:14)
at maestro.cli.device.DeviceService.listIOSDevices(DeviceService.kt:164)
at maestro.cli.device.DeviceService.listDevices(DeviceService.kt:124)
at maestro.cli.device.DeviceService.listConnectedDevices(DeviceService.kt:114)
at maestro.cli.device.PickDeviceInteractor.pickDeviceInternal(PickDeviceInteractor.kt:33)
at maestro.cli.device.PickDeviceInteractor.pickDevice(PickDeviceInteractor.kt:14)
at maestro.cli.util.MaestroFactory.createMaestro(MaestroFactory.kt:35)
at maestro.cli.command.TestCommand.call(TestCommand.kt:63)
at maestro.cli.command.TestCommand.call(TestCommand.kt:31)
at picocli.CommandLine.executeUserObject(CommandLine.java:1933)
at picocli.CommandLine.access$1200(CommandLine.java:145)
at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2332)
at picocli.CommandLine$RunLast.handle(CommandLine.java:2326)
at picocli.CommandLine$RunLast.handle(CommandLine.java:2291)
at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2159)
at picocli.CommandLine.execute(CommandLine.java:2058)
at maestro.cli.AppKt.main(App.kt:97)
i#is-MacBook-Pro samples % maestro test android-flow.yaml
It seems to me that you currently have two JDK versions, for Maestro it works fine if you install JDK 11 and delete the other versions and then check
I'm just starting out with Scala and have been following its Getting Started instructions. The second part of the instruction involves pulling the hello-world template by running the sbt new scala/hello-world.g8 command.
My problem is that it keeps on giving me this error:
Error: Could not find or load main class Anne
Caused by: java.lang.ClassNotFoundException: Anne
I'd like to know the reason for this, as well as any possible fix I might use.
The following is my insight and attempts on fixing this problem.
Insight:
1. I might have a problem with java installation/scala/sbt installation that needs this class Anne since even with other sbt commands like sbt sbtVersion I get the same error
Attempts:
1. Change command to retrieve from full url:
sbt new https://github.com/scala/hello-world.g8
2.(Edit): Previously I thought the repository scala/hello-world.g8 did not exist and tried getting from other repositories with no luck and with the same error as above. However it was pointed out below that the repository actually exists in this url https://github.com/scala/hello-world.g8, thanks Dmytro Mitin.
I was looking into the incorrect account (sbt) instead of (scala)
(Edit): Day 2
3. Uninstall/Reinstall sbt -- still getting the error
4. Checked if java running properly by compiling sample code and running ( successful )
I was actually running the command in Visual Studio Code's bash terminal. I tried running it with cmd and everything's now working fine.
I am new to WebSphere Application Server.Getting this error in WAS Console while executing junit class (RunAs--> JUnit Test)
Running as Junit Test in Rational Application Developer
Actual Error Message is:
JVMJ9TI001E Agent library D:\Program Files\IBM\SDPShared\plugins\org.eclipse.tptp.platform.jvmti.runtime_4.7.0.v201110280852\agent_files\win_em64t\JPIBootLoader could not be opened (D:\Program Files\IBM\SDPShared\plugins\org.eclipse.tptp.platform.jvmti.runtime_4.7.0.v201110280852\agent_files\win_em64t\JPIBootLoader is not a valid Win32 application. )
JVMJ9VM015W Initialization error for library j9jvmti24(-3): JVMJ9VM009E J9VMDllMain failed .
Came Across this below links and tried but can't able to resolve"
link1-IBM
link2-IBM
I am using windows 10 64 bit, RAD 8.0.4 , WAS 7.0.23 ,Junit 4.12.
Help me to resolve this issue. Thanks in Advance.
Is the Junit running within the IDE's JVM? To check click on Run > Run Configurations, and look for the unit test you are trying to run. Then click on the JRE tab. It should show the Project Execution Environment.
Also, you're on a considerably old version of RAD and WAS. Any reason you can't upgrade?
I'm new to IntelliJ IDEA and can't understand the cause for the following error when trying to debug unit tests:
Error:gradle-resources-test:StorageService_test: java.lang.NoClassDefFoundError: org/apache/tools/ant/util/ReaderInputStream when debugging tests in IntelliI IDEA
although the code is building fine I can't debug because the debugger give me this error and fail to start.
I've got a project in Selenium/Java with tests that normally run on chromedriver.exe (I work on Windows) - no problems at all.
I have recently decided to add the project to our TeamCity that runs on Linux and since it cannot run tests on a browser, I want to switch to PhantomJS driver.
I've tried multiple variations of all the solutions I've found online and still can't get it working.
Currently I've got the phantomjs binary file in my resources, and I get the driver like this in an enum class:
PHANTOMJS {
#Override
public WebDriver initNewDriver() {
System.setProperty("phantomjs.binary.path", ClassLoader.getSystemResource(RELATIVE_PATH_TO_FILE_IN_RESOURCES).getFile());
return new PhantomJSDriver();
}
Then in the test class I start with driver.get(SOME_URL) - which is the furthest it ever got.
No matter what I do, when I tried to run it on TeamCity through 'clean test', I get something like this:
[userLoginTest] java.lang.IllegalStateException: The driver executable does not exist: /opt/buildAgent1/work/c4641c7cfd3331f7/web/drivers/phantomjslinux/phantomjs
[14:41:41]
[userLoginTest] java.lang.IllegalStateException: The driver executable does not exist: /opt/buildAgent1/work/c4641c7cfd3331f7/web/drivers/phantomjslinux/phantomjs
at com.google.common.base.Preconditions.checkState(Preconditions.java:518)
at org.openqa.selenium.remote.service.DriverService.checkExecutable(DriverService.java:123)
at org.openqa.selenium.phantomjs.PhantomJSDriverService.findPhantomJS(PhantomJSDriverService.java:254)
at org.openqa.selenium.phantomjs.PhantomJSDriverService.createDefaultService(PhantomJSDriverService.java:190)
at org.openqa.selenium.phantomjs.PhantomJSDriver.(PhantomJSDriver.java:104)
at org.openqa.selenium.phantomjs.PhantomJSDriver.(PhantomJSDriver.java:94)
at test.core.base.SeleniumDriver$3.initNewDriver(SeleniumDriver.java:47)
at test.core.base.TestBase.(TestBase.java:25)
I don't really understand TeamCity well and it's difficult to find solutions that are applicable to my project and that I actually understand. So any help is welcome. Thanks :)
Solved by running npm install phantomjs on the server and using PhantomJS from there.