Is it possible to run Calabash-IOS, iOS automated tests on Ubuntu? - ios

I know that it's impossible to code the test on Ubuntu since I need Apple's XCODE, but I would like to know if, once coded, it is possible to run the automated tests on Ubuntu.
Thanks.

Related

Chrome browserless Selenium on bamboo

I've developed a framework which runs selenium tests with no problem on my local computer.
I also have developed a pipeline on Bamboo to execute those tests. It does, problem is I have no chrome browser installed on bamboo and I get the error saying "There is no chrome binary" obviously. There is no chance to install anything on bamboo, so I need to run these tests with no browser (also headless).
I've checked this: https://github.com/browserless/chrome
Sounds good to what I want to achieve but I don't know how to do it.
Do I need to run docker by command and then point my driver to the port or what?
Can anyone shed some light? I pretty lost and there are not much examples (or I don't know how to find them)
Thanks!!

iOS app not uninstall and reinstalling between tests on Browserstack App Automate

Currently running a smoke test suite on IntelliJ against Browserstack App Automate (Java, Appium, and Cucumber to write the test files).
The issue comes from running iOS tests as a series/suite. When one test ends and another begins, the app hasn't reset or reinstalled and starts from where the other app ended (with a new user created). For each test, we need the app to start from afresh and this doesn't seem to be happening. Android tests for our app work just fine, but this issue only happens when running them on iOS.
Has anyone encountered a similar issue?
Could you execute the tests by setting the capability "fullReset" to "true". Read more on this in the link: http://appium.io/docs/en/writing-running-appium/other/reset-strategies/index.html
Then execute the command "driver.resetApp()" after the execution of one test and before the beginning of the second?

How to dockerize Xcode

For CI purposes I have a need to set up a cluster of build slaves capable of building iOS apps. For now I'm relying on a single MacMini -with the aim to deploy several more in the future- and I'd like to virtualize several slaves on top of it. Some of these virtual slaves will build the iOS app, others will be smaller Linux slaves for miscellaneous purposes.
I'm completely new to Docker, so my main question is whether it's possible to dockerize Xcode 9.2 and/or MacOS in order to virtualize my iOS build slaves. I've seen very little literature out there on whether this can be achieved and I've found some images in hub.docker.com but they're not documented and don't appear to be very popular.
I'm going through a Docker tutorial right now and eventually will be attempting this -and if I'm successful I'll be answering my own question here for the benefit of others- but given the lack of information I have doubts on whether it is even possible or where I should even start.
Any tips or pointers on this would be greatly appreciated.
Or if anyone knows for fact that this is not possible and can explain why, that would also save me a lot of time.
OS X does not use the Linux kernel, so it cannot run in a Docker container
XCode is not open-sourced and does not have a Linux installer, so it cannot be used in a Linux Docker image.
It seems like your best bet is to build a Packer template using something like packer-macos osx-vm-templates and integrate that into your pipeline.
Look at Docker-OSX which runs macOS with Xcode support inside Docker.
You can connect to that macOS via SSH or VNC. It might be possible to use the same approach in CI/CD.
Related link from readme: "I want to use Docker-OSX for CI/CD-related purposes (sign into Xcode, Transporter)"

How to run travis-ci locally for Objective-C language

I'm trying to run travis-ci locally.
I'm following this thread: How to run travis-ci locally and https://docs.travis-ci.com/user/common-build-problems/#Troubleshooting-Locally-in-a-Docker-Image
But I think I chose the wrong image because it hasn't got xcodebuild
Any idea which image should I choose instead?
You can only run the docker images for local debugging. The MacOS images are not docker images, and cannot be used to be run locally. This would also violate license terms of Apple, so this will not happen in the conceivable future.

Can I run grails integration & functional tests against a running server?

I'm finding the feedback look pretty slow when running integration and functional tests in Grails. Is there a way I can run them against a running server instance while I'm writing the tests, to save on server startup time each time they're executed?
You can use grails interactive which does what you want without starting a server. It starts a JVM and keeps it running and you can use it to run unit and integration tests. Keep in mind that you'll eventually run out of memory and need to restart periodically. See http://docs.grails.org/latest/guide/gettingStarted.html#usingInteractiveMode
Also in 1.3.5 you can run functional tests against a running server. Use the baseUrl attribute described in section 9.3 at http://grails.org/doc/latest/
there's an option --baseUrl
e.g.
grails test-app --baseUrl=http://localhost:8080/myapp/
that runs tests against a running instance, one draw back is that the slate isn't wiped clean after a test, so if your test writes to the db, uploads a file, or some other permanent change to the application, then you may have to do some tearDown.
This is briefly documented at the end of the function testing section of the grails docs
http://grails.org/doc/latest/guide/testing.html#functionalTesting
It's useful for writing/debugging functional tests
I'm using Grails 1.3.5 and the EasyB plugin for stories in the context of functional tests.
Take a look at http://padcom13.blogspot.com/2010/10/grails-easyb-and-selenium.html for step-by-step instructions.

Resources