mirror of
https://github.com/copyrighttxt/watrbx-game-engine.git
synced 2026-09-07 13:57:48 +00:00
GEEKING
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
[caps]
|
||||
platformName = "Android"
|
||||
#deviceName = "06df4e0e"
|
||||
deviceName = "HT4A1JT02469"
|
||||
platformVersion = "6.0.1"
|
||||
app= "./ROBLOX_CI_GT2.apk"
|
||||
appPackage = "wtf.watrbx.client.dev"
|
||||
appWaitActivity = "wtf.watrbx.client.ActivitySplash"
|
||||
appActivity = "wtf.watrbx.client.ActivitySplash"
|
||||
@@ -0,0 +1,41 @@
|
||||
# encoding: utf-8
|
||||
require 'rspec/expectations'
|
||||
require 'appium_lib'
|
||||
require 'cucumber/ast'
|
||||
require 'page_helper'
|
||||
require 'random_data'
|
||||
require 'require_all'
|
||||
require 'simplecov'
|
||||
require 'simplecov-rcov'
|
||||
SimpleCov.formatters = [
|
||||
SimpleCov::Formatter::HTMLFormatter,
|
||||
SimpleCov::Formatter::RcovFormatter
|
||||
]
|
||||
SimpleCov.start
|
||||
|
||||
require './lib/page_helper'
|
||||
require './lib/data_helper'
|
||||
require_all './lib/pages'
|
||||
|
||||
class AppiumWorld
|
||||
end
|
||||
|
||||
case ENV['OS']
|
||||
when 'ios'
|
||||
caps = Appium.load_appium_txt file: File.expand_path('../ios/appium.txt', __FILE__), verbose: true
|
||||
when 'android'
|
||||
caps = Appium.load_appium_txt file: File.expand_path('../android/appium.txt', __FILE__), verbose: true
|
||||
end
|
||||
|
||||
WAITTIME = 35
|
||||
|
||||
Appium::Driver.new(caps)
|
||||
Appium.promote_appium_methods AppiumWorld
|
||||
Appium.promote_singleton_appium_methods [DataHelper, PageHelper]
|
||||
|
||||
World do
|
||||
AppiumWorld.new
|
||||
end
|
||||
|
||||
World PageHelper
|
||||
World DataHelper
|
||||
@@ -0,0 +1,36 @@
|
||||
system 'killall node'
|
||||
system 'appium --log-level error&'
|
||||
sleep 15
|
||||
|
||||
begin
|
||||
at_exit do
|
||||
system 'killall node'
|
||||
end
|
||||
rescue
|
||||
puts 'AUTO: appium not killed at exit'
|
||||
end
|
||||
|
||||
Before do
|
||||
begin
|
||||
$driver.start_driver
|
||||
@browser = $driver
|
||||
rescue
|
||||
puts 'AUTO: driver not initialized'
|
||||
end
|
||||
end
|
||||
|
||||
After do |scenario|
|
||||
begin
|
||||
if $driver
|
||||
if scenario.failed?
|
||||
filename = "FAIL-#{scenario.__id__}.png"
|
||||
filename = 'reports/' + filename
|
||||
screenshot(filename)
|
||||
embed(filename, 'image/png', 'SCREENSHOT')
|
||||
end
|
||||
$driver.driver_quit
|
||||
end
|
||||
rescue
|
||||
puts 'AUTO: driver not exist'
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,8 @@
|
||||
[caps]
|
||||
platformName = "iOS"
|
||||
deviceName = "iPad Mini"
|
||||
platformVersion = "9.2.1"
|
||||
sendKeyStrategy = "setValue"
|
||||
udid = "e4b31a41fab6a4ad9ccd98891d92e517f462a922"
|
||||
#udid = "b2fb181e04d7b46a6461d692f035be6ea04b8875"
|
||||
bundleId="wtf.watrbx.robloxmobile"
|
||||
Reference in New Issue
Block a user