chemlab 0.3.0 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/chemlab/configuration.rb +1 -1
- data/lib/chemlab/element.rb +1 -0
- data/lib/chemlab/page.rb +1 -1
- data/lib/chemlab/runtime/browser.rb +7 -8
- data/lib/chemlab/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 07bc21e85bd30535258248b34722848feed23de49fea1217442efa6f5fe86f9b
|
4
|
+
data.tar.gz: d38fbd55e058dfdc124d3d497fc45928bdea73c3eceaaf7f81c7330f18d793bb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2f621b4f87dbf07474a77fb2ad309b9cfbbb34cc9f1e5158bfc343d58e3005d5612ee38f8877410c444c44280031f2bb67a2516d078c08e22071a16f726dd1a1
|
7
|
+
data.tar.gz: e837e155b3743c861e238de0da9f3306a5a2222c6df73d4fdb3d7655626ca05c2cefd89f8db5433023c8a65f2df3378190818aef1bee9d63564e7f6b4369a811
|
data/lib/chemlab/element.rb
CHANGED
data/lib/chemlab/page.rb
CHANGED
@@ -1,7 +1,5 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require 'active_support/configurable'
|
4
|
-
|
5
3
|
module Chemlab
|
6
4
|
module Runtime
|
7
5
|
# The browser configurator
|
@@ -13,25 +11,26 @@ module Chemlab
|
|
13
11
|
|
14
12
|
def initialize(browser_options)
|
15
13
|
@browser_options = browser_options
|
14
|
+
@session = Session.new(browser_options)
|
16
15
|
end
|
17
16
|
|
18
17
|
def self.navigate_to(page_class)
|
19
|
-
Chemlab.configuration.browser.navigate_to(page_class.
|
18
|
+
Chemlab.configuration.browser.navigate_to(page_class.path)
|
20
19
|
end
|
21
20
|
|
22
|
-
def navigate_to(
|
23
|
-
@session
|
24
|
-
@session.engine.goto(Chemlab.configuration.base_url +
|
21
|
+
def navigate_to(path)
|
22
|
+
@session ||= Chemlab.configuration.browser.session
|
23
|
+
@session.engine.goto(Chemlab.configuration.base_url + path)
|
25
24
|
end
|
26
25
|
|
27
26
|
# An individual session
|
28
27
|
class Session
|
29
28
|
attr_reader :engine
|
30
29
|
|
31
|
-
def initialize(
|
30
|
+
def initialize(browser)
|
32
31
|
@engine = Watir::Browser.new(*browser)
|
33
32
|
|
34
|
-
@engine.goto(Chemlab.configuration.base_url)
|
33
|
+
# @engine.goto(Chemlab.configuration.base_url)
|
35
34
|
end
|
36
35
|
|
37
36
|
def current_url
|
data/lib/chemlab/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chemlab
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- GitLab Quality
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-03-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: debase
|