Sha256: b37a8827cad43fce4e95e230a362fabc6df78d377d7f07fd25fd355a529a5259
Contents?: true
Size: 1.39 KB
Versions: 3
Compression:
Stored size: 1.39 KB
Contents
#!/usr/bin/env ruby require 'commander/import' require_relative '../lib/xcmonkey' require_relative '../lib/xcmonkey/describer' require_relative '../lib/xcmonkey/logger' require_relative '../lib/xcmonkey/driver' require_relative '../lib/xcmonkey/version' module Xcmonkey program :version, VERSION program :description, 'xcmonkey is a tool for doing randomised UI testing of iOS apps' command :test do |c| c.syntax = 'xcmonkey test [options]' c.description = 'Runs monkey test' c.option('-u', '--udid STRING', String, 'Set device UDID') c.option('-b', '--bundle-id STRING', String, 'Set target bundle identifier') c.option('-d', '--duration SECONDS', Integer, 'Test duration in seconds') c.action do |args, options| options.default(duration: 60) params = { udid: options.udid, bundle_id: options.bundle_id, duration: options.duration } Xcmonkey.new(params).run end end command :describe do |c| c.syntax = 'xcmonkey describe [options]' c.description = 'Describes given point' c.option('-u', '--udid STRING', String, 'Set device UDID') c.option('-x', '--x STRING', 'Point `x` coordinate') c.option('-y', '--y STRING', 'Point `y` coordinate') c.action do |args, options| params = { udid: options.udid, x: options.x, y: options.y } Describer.new(params).run end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
xcmonkey-0.2.0 | bin/xcmonkey |
xcmonkey-0.1.2 | bin/xcmonkey |
xcmonkey-0.1.1 | bin/xcmonkey |