diff --git a/README.md b/README.md index 77ad757..7fe78bd 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ This code is provided on an "AS-IS” basis without warranty of any kind, either 2. Test Object Credentials * Add your TestObject API Key: ``` - $ export TESTOBJECT_API_KEY= + $ export SAUCE_API_KEY= $ export APPIUM_URL= ``` diff --git a/Rakefile b/Rakefile index 0411590..a73afaf 100644 --- a/Rakefile +++ b/Rakefile @@ -11,6 +11,8 @@ task :default => :spec desc "Run Tests on Android" task :test_android_device do ENV['platformName'] = 'Android' + ENV['platformVersion'] = '9' + ENV['deviceName'] = 'Google Pixel XL' ENV['JUNIT_DIR'] = 'junit_reports/android_device' Rake::Task[:run_rspec].execute diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 1476656..647a3dd 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -11,8 +11,10 @@ config.before(:each) do |example| caps = { - testobject_api_key: ENV['TESTOBJECT_API_KEY'], - deviceName: ENV['platformName'], + testobject_api_key: ENV['SAUCE_API_KEY'], + platformName: ENV['platformName'], + platformVersion: ENV['platformVersion'], + deviceName: ENV['deviceName'], testobject_test_name: example.full_description } @@ -25,7 +27,7 @@ end config.after(:each) do |example| - url = "https://#{ENV['TESTOBJECT_API_KEY']}:#{'blank'}@app.testobject.com/api/rest/v1/appium/session/#{@sessionid}/test" + url = "https://#{ENV['SAUCE_API_KEY']}:#{'blank'}@app.testobject.com/api/rest/v1/appium/session/#{@sessionid}/test" call = {url: url, method: :put,