superbot 0.1.29 → 0.1.30

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bd613f0c67581ca3218dc7c34f6d78f42399a5cf5a0a44df8867f40dd159d410
4
- data.tar.gz: 521ca7e541991375f6e65a71a711456bc0de74c9928a4c8779ecc84039a03f42
3
+ metadata.gz: 6d65d2c27b2fc6dd564924c1e5b65fee296150a53ed0f36920bfe28960ae1308
4
+ data.tar.gz: a4aa43bafc34c6e7f7d7acc8169caced0c19c2ae9a75e265440c8f8dc9ca00a5
5
5
  SHA512:
6
- metadata.gz: 7e0b07d08071429bdb9f4443428e7d43a6c2eac507d3073f12afcb2d2658d95e48abde14ea862644375480ee4d199742a09ffdfa0cbb2193b420ed4aa69b0ba0
7
- data.tar.gz: 717aaa0dc1c2e729d69a4472fe02f6b1eefe59b3ae196d56fd9f159d5c5ce3a8670d86d37fafdcf16cafa00c205c09711ee6fd778294b1645bc7194cf8e78dbf
6
+ metadata.gz: 5340c6145890e9c53603d828d9c01cffeb86762c8711fa4bc4ce2d63f8260d8b5b497d8d066513f896f24ccc67e2039df18b51f805287e2b7906edac7ab46316
7
+ data.tar.gz: 860e15575bb13312181e6c91252da59f4518bfc951f421a6caba82e19ebf8c0e608027a0ce80f19fd145613c4e5a99779902bbab90bc1c9be6154a0663c950c8
data/Gemfile CHANGED
@@ -9,5 +9,4 @@ unless ENV['SUPERBOT_USE_RUBYGEMS'] == "yes"
9
9
  gem "superbot-selenium-webdriver", path: "../superbot-selenium-webdriver"
10
10
  gem "superbot-teleport", path: "../superbot-teleport"
11
11
  gem "superbot-cloud", path: "../superbot-cloud"
12
- gem "superbot-local", path: "../superbot-local"
13
12
  end
data/Gemfile.lock CHANGED
@@ -1,15 +1,15 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- superbot (0.1.29)
4
+ superbot (0.1.30)
5
5
  clamp (= 1.2.1)
6
6
  kommando (~> 0.1)
7
7
  launchy (= 2.4.3)
8
8
  sinatra (= 2.0.4)
9
9
  sinatra-silent (= 0.0.1)
10
- superbot-cloud (~> 0.1.19)
10
+ superbot-cloud (~> 0.1.21)
11
11
  superbot-selenium-webdriver (~> 1.0.1)
12
- superbot-teleport (~> 0.2.2)
12
+ superbot-teleport (~> 0.2.3)
13
13
  zaru (= 0.2.0)
14
14
 
15
15
  GEM
@@ -126,13 +126,13 @@ GEM
126
126
  rack-protection (= 2.0.4)
127
127
  tilt (~> 2.0)
128
128
  sinatra-silent (0.0.1)
129
- superbot-cloud (0.1.19)
129
+ superbot-cloud (0.1.21)
130
130
  marcel (= 0.3.3)
131
131
  multipart-post (= 2.0.0)
132
132
  superbot-selenium-webdriver (1.0.1)
133
133
  chromedriver-helper (= 2.1.0)
134
134
  selenium-webdriver (= 3.141.0)
135
- superbot-teleport (0.2.2)
135
+ superbot-teleport (0.2.3)
136
136
  excon
137
137
  thor (0.20.0)
138
138
  tilt (2.0.9)
data/lib/superbot.rb CHANGED
@@ -43,7 +43,7 @@ Clamp.allow_options_after_parameters = true
43
43
 
44
44
  require_relative "superbot/version"
45
45
  require_relative "superbot/cli/validations"
46
- %w(selenium cloud teleport local).each do |microgem|
46
+ %w(selenium cloud teleport).each do |microgem|
47
47
  begin
48
48
  require "superbot/#{microgem}"
49
49
  rescue LoadError
@@ -16,14 +16,14 @@ module Superbot
16
16
  private
17
17
 
18
18
  def open_superside
19
- options = Selenium::WebDriver::Chrome::Options.new
19
+ options = ::Selenium::WebDriver::Chrome::Options.new
20
20
  options.add_argument("app=about:blank")
21
21
  options.add_argument("no-sandbox")
22
22
  options.add_extension(File.join(File.dirname(__dir__), '../..', 'bin', 'superside.crx'))
23
- browser = Selenium::WebDriver.for :chrome, options: options
23
+ browser = ::Selenium::WebDriver.for :chrome, options: options
24
24
 
25
25
  # close browser window when extension is loaded
26
- sleep 0.5
26
+ sleep 1
27
27
  browser.close
28
28
  end
29
29
  end
@@ -22,10 +22,6 @@ module Superbot
22
22
  subcommand ["run"], "Run a project", RunCommand
23
23
  end
24
24
 
25
- if defined?(::Superbot::Local::CLI::RootCommand)
26
- subcommand ["local"], "Show local commands", ::Superbot::Local::CLI::RootCommand
27
- end
28
-
29
25
  if defined?(::Superbot::Cloud::CLI::RootCommand)
30
26
  subcommand ["cloud"], "Show cloud commands", ::Superbot::Cloud::CLI::RootCommand
31
27
  end
@@ -40,12 +36,6 @@ module Superbot
40
36
  warn exc.message
41
37
  warn exc.backtrace.join("\n")
42
38
  end
43
-
44
- def subcommand_missing(name)
45
- return super unless name == 'local'
46
-
47
- abort "Subcommand '#{name}' requires gem superbot-#{name} to be installed"
48
- end
49
39
  end
50
40
  end
51
41
  end
@@ -3,7 +3,7 @@
3
3
  module Superbot
4
4
  module Convert
5
5
  module Web
6
- def self.register(sinatra)
6
+ def self.registered(sinatra)
7
7
  sinatra.helpers do
8
8
  def capybara_runner
9
9
  @capybara_runner ||= Superbot::Capybara::Runner.new
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Superbot
4
- VERSION = "0.1.29"
4
+ VERSION = "0.1.30"
5
5
  end
data/lib/superbot/web.rb CHANGED
@@ -14,6 +14,10 @@ module Superbot
14
14
  @sinatra.set :silent_access_log, false
15
15
  @sinatra.server_settings[:Silent] = true
16
16
 
17
+ @sinatra.set :webdriver_type, webdriver_type
18
+ @sinatra.set :webdriver_url, Superbot.webdriver_endpoint(webdriver_type)
19
+ @sinatra.set :region, region
20
+
17
21
  @sinatra.before do
18
22
  headers['Access-Control-Allow-Methods'] = 'GET, POST, PUT, DELETE, OPTIONS'
19
23
  headers['Access-Control-Allow-Origin'] = '*'
@@ -29,11 +33,9 @@ module Superbot
29
33
  "PONG"
30
34
  end
31
35
 
32
- if defined?(Superbot::Teleport::Web)
33
- Superbot::Teleport::Web.register(@sinatra, webdriver_type: webdriver_type, region: region)
34
- end
35
- Superbot::Cloud::Web.register(@sinatra) if defined?(Superbot::Cloud::Web)
36
- Superbot::Convert::Web.register(@sinatra) if defined?(Superbot::Convert::Web)
36
+ @sinatra.register Superbot::Teleport::Web if defined?(Superbot::Teleport::Web)
37
+ @sinatra.register Superbot::Cloud::Web if defined?(Superbot::Cloud::Web)
38
+ @sinatra.register Superbot::Convert::Web if defined?(Superbot::Convert::Web)
37
39
  end
38
40
 
39
41
  def self.run!(options = { webdriver_type: 'cloud', region: nil })
data/superbot.gemspec CHANGED
@@ -38,8 +38,8 @@ Gem::Specification.new do |spec|
38
38
  spec.add_runtime_dependency "launchy", "2.4.3"
39
39
  spec.add_runtime_dependency "sinatra-silent", "0.0.1"
40
40
  spec.add_runtime_dependency "kommando", "~> 0.1"
41
- spec.add_runtime_dependency "superbot-cloud", "~> 0.1.19"
42
- spec.add_runtime_dependency "superbot-teleport", "~> 0.2.2"
41
+ spec.add_runtime_dependency "superbot-cloud", "~> 0.1.21"
42
+ spec.add_runtime_dependency "superbot-teleport", "~> 0.2.3"
43
43
  spec.add_runtime_dependency "superbot-selenium-webdriver", "~> 1.0.1"
44
44
 
45
45
  spec.add_development_dependency "bundler", "~> 1.17"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: superbot
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.29
4
+ version: 0.1.30
5
5
  platform: ruby
6
6
  authors:
7
7
  - Superbots
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-12-10 00:00:00.000000000 Z
11
+ date: 2018-12-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: clamp
@@ -100,28 +100,28 @@ dependencies:
100
100
  requirements:
101
101
  - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: 0.1.19
103
+ version: 0.1.21
104
104
  type: :runtime
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - "~>"
109
109
  - !ruby/object:Gem::Version
110
- version: 0.1.19
110
+ version: 0.1.21
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: superbot-teleport
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  requirements:
115
115
  - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: 0.2.2
117
+ version: 0.2.3
118
118
  type: :runtime
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
122
  - - "~>"
123
123
  - !ruby/object:Gem::Version
124
- version: 0.2.2
124
+ version: 0.2.3
125
125
  - !ruby/object:Gem::Dependency
126
126
  name: superbot-selenium-webdriver
127
127
  requirement: !ruby/object:Gem::Requirement
@@ -326,7 +326,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
326
326
  version: '0'
327
327
  requirements: []
328
328
  rubyforge_project:
329
- rubygems_version: 2.7.7
329
+ rubygems_version: 2.7.8
330
330
  signing_key:
331
331
  specification_version: 4
332
332
  summary: Superbot Testing