webdriver 테스트를 여러 서버에 적용해야합니다. 내 솔루션 명령 행 매개 변수에 전달했지만optparse ruby에서 웹 서버용 대상 서버 설정
루비 webdriver/E2E/*. RB -s = localhost를
또는
루비 webdriver 사용하여 아래의 코드를 실행할 때 /e2e/*.rb --server = localhost
그러나 다음 오류가 발생합니다. 나는
opts.on('-serv', '--server server', 'Server to run tests against') do|server|
에
opts.on('-s', '--server server', 'Server to run tests against') do|server|
을 변경
C:/Ruby193/lib/ruby/1.9.1/test/unit.rb:49:in `process_args': invalid argument: -s=localhost (OptionParser::InvalidArgument)
from C:/Ruby193/lib/ruby/1.9.1/minitest/unit.rb:891:in `_run'
from C:/Ruby193/lib/ruby/1.9.1/minitest/unit.rb:884:in `run'
from C:/Ruby193/lib/ruby/1.9.1/test/unit.rb:21:in `run'
from C:/Ruby193/lib/ruby/1.9.1/test/unit.rb:326:in `block (2 levels) in autorun'
from C:/Ruby193/lib/ruby/1.9.1/test/unit.rb:27:in `run_once'
from C:/Ruby193/lib/ruby/1.9.1/test/unit.rb:325:in `block in autorun'
test.rb
require 'test/unit'
require 'optparse'
class SuperTestClass < Test::Unit::TestCase
def setup
@server = "https://localhost/"
optparse = OptionParser.new do|opts|
opts.on('-s', '--server server', 'Server to run tests against') do|server|
@server = server
end
end
...
end
...
end
UPDATE
다음과 같은 오류를 얻을
하지만 난 내 이론을 증명할 수 있도록이