Jenkins : TestFairy Plugin
This plugin helps you to upload Android APKs or iOS IPA files to www.testfairy.com
Older versions of this plugin may not be safe to use. Please review the following warnings before using an older version:
How to use
Select TestFairy iOS/Android Uploader from Add post-build action menu
Job Configuration:
- The API Key can be found in your account settings
To make sure Jenkins also uploads your iOS dSYMs to TestFairy, configure the Xcode that builds the app on the Jenkins server to run a special script. Follow these instructions.
The resulted TestFairy links will be listed in the console output
Important f****or Advanced Uploader only:
- You should configure the "Path To Keystore file" and the corresponding storepass & alias.
- You should configure "TestFairy Android Environment" on http://localhost:8080/configure for example:
Custom changelog
In order to add your own changelog or comments, please create a text file in the following location:
$JENKINS_HOME/jobs/$JOB_NAME/builds/$BUILD_ID/testfairy_change_log
The content of this file will override the default changelog.
Private Cloud / On-Premise support
In case you are using our Private Cloud or On-Premise product
please define an TESTFAIRY_UPLOADER_SERVER
environment variable.
You can do it by going to Manage Jenkins -> Configure
Under section Global Properties, check Environment variables checkbox. Now Jenkins allow us to add key and value pairs.
The name should be TESTFAIRY_UPLOADER_SERVER
and the value will be your server domain.
The following line should be printed at your next job console output:
The server will be https://YOUR-PRIVATE-SERVER-SUBDOMAIN.testfairy.com/
Development Guide
Build
# Build
docker run -it --rm -v `pwd`:`pwd` -w `pwd` --env TF_API_KEY=<yourkey> androidsdk/android-30:latest bash scripts/build.sh
# Use built binary
ls -a target/TestFairy.hpi
Develop
# Launch development environment
docker run -it --rm -v `pwd`:`pwd` -w `pwd` --env TF_API_KEY=<yourkey> androidsdk/android-30:latest bash
# inside docker
# Attempt first build and prepare environment
bash scripts/build.sh
# Develop new features
# Run tests after code change
bash scripts/retry.sh
# Quit docker and REMOVE environment while keeping the changes in source code
exit
# Push
git ...
How to add a new feature?
- Create a recorder (example:
src/main/java/org/jenkinsci/plugins/testfairy/TestFairyIosRecorder.java
) - Create a UI resource for the recorder (example:
src/main/resources/org/jenkinsci/plugins/testfairy/TestFairyIosRecorder/**/*.jelly
) - Create a new test (example:
scripts/upload_test/UploadTest.xml
) - Set it up (example:
scripts/upload_test/upload_test.sh
) - Add it to the suite (example:
scripts/test_jenkings_plugin.sh
)