UI tests failing in Xcode 14 - uitest

Failed to Error Domain=com.apple.dt.xctest.ui-testing.error Code=10001 "Application is not running"
All of the UI tests were working in Xcode 13 but once I updated to 14, they all failed. Also noted that all unit tests pass and the issue is only with UI tests. I've tried XCUIApplication launch but that didn't help.

Related

Error build VSTS - VSTest TASK - OpenQA.Selenium.WebDriverException: unknown error: cannot find Chrome binary

I'm still trying to run my tests as integration continues in VSTS, however, a bug is being presented in the build:
[error] OpenQA.Selenium.WebDriverException: unknown error: can not find Chrome binary
I'm running the build on the agent HOSTED VS2017 and in the details of it, says that it has Chrome installed. However, there is an error when attempting to execute.
Anyone know if there's any other way?

TeamCity NUnitTestRunner crashes with Mono 5.4.1

I was wondering why my NUnit tests were suddenly terminating successfully after 30 seconds whereas they usually take at least 20 minutes. Then I looked into the build log and found that after upgrading the mono version on our build agent to v 5.4.1, the test runner crashed with exit code 134.
After doing some research, I found out the following:
- The test runner works when using mono 4.8.1 (which we have installed, too), but the test code won't compile with it
- Ì also tried launching th erunner manually like so: /Library/Frameworks/Mono.framework/Versions/5.4.1/bin/mono -v /Applications/TeamCity/buildAgent/plugins/dotnetPlugin/bin/JetBrains.BuildServer.NUnitLauncher.exe which gave me the following error: [1] 3461 abort /Library/Frameworks/Mono.framework/Versions/5.4.1/bin/mono -v with the 3461changing every time I retry.
- According to this thread, exit code 134 means that the program crashed.
Due to the error output, I am not sure, whether it's the TeamCity test runner that crashes, mono that crashes or TeamCity that makes mono crash.
Any help appreciated :)
I finally figured it out myself. Apparently, Mono 5.4.1 lacks important NUnit2 components that were shipped with Mono 5.2 and older. To make tests work again, I had to add the NUnit.Console NuGet-package (not NUnit.ConsoleRunner as it lacks required extensions) and update the TeamCity build step to use the nunit3-console as described here.
For others that may come across this, I fixed this by changing the NUnit build steps from NUNit 2.6.3 to the NUnit 3.10. I didn't change any of my code / packages, just the TC configuration.

Running webdriver IEDriver on Jenkins fails

I have a small C# webdriver test suite dll which I recently created...
Runs fine in Visual Studio
Runs from the command line perfectly using the NUnit 3 console runner.
I have Jenkins installed on my laptop (for testing before I put it into my live Jenkins), running with my Windows credentials. When I execute the test suite using the same NUnit3 console runner command I used before, all the tests fail, can't even log in as it can't find any elements. I took screenshots with Selenium & it's just a black rectangle!
Anyone have any ideas on how to get IE behaving - I bet it's a Windows permissions thing from Jenkins. Thanks!
I'll answer my own question.
Turns out you can't do what I'm attempting - it's a known issue with the way IE is built. What I had to do is install a new Jenkins node on another machine and get that to run the IE tests. That way it did work.

vstest.console.exe open nunit GUI but doesn't run tests

I have a visual studio project which includes a test with selenium code. I am trying to run this using vstest.console.exe using command
vstest.console.exe C:\Code\SampleReportsProject\SampleReportsProject\bin\Debug\SampleReportsProject.dll
On running this command, it opens NUnit GUI window but doesn't execute the test.
On running again, I get message
Starting test execution, please wait... Warning: No test is available
in C:\Code\SampleReportsProject\SampleReportsProje
ct\bin\Debug\SampleReportsProject.dll. Make sure that installed test
discoverers & executors, platform & framework version settings are
appropriate and try again.

Tests are not executed - Bot Issue: Test target MyTests encountered an error (Test session exited(0) without checking in

I'm using Xcode Continuous Integration for making builds.
OS X Server 4.1,
Mac OS X 10.10.4,
Xcode 6.3.1
My all test cases start failing after OS X update OS X 10.10.4 (Build 14E17e) and Xcode 6.3.2. I'm not sure whether these update cause the issue or something else.
Error: Bot Issue: error. Uncategorized. Issue: Test target MyTests encountered an error (Test session exited(0) without checking in
Any idea what is the cause of the issue?
Observation:
I ran test cases using xctool all the test cases are passing however when I ran test cases in release mode, they are failing.
My issue is resolved. I don't know the exact reason however I changed sign-in '-' to Don't SignIn in build setting of all tests targets and I found one crash while running test cases in released mode. My issue is resolved after fixing these two issues.