isomorfeus-puppetmaster 0.6.2 → 0.6.3

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: 17136be066c39325b537f20a9f5f093512bff982e2e8f64f9ecf9dace486a8b5
4
- data.tar.gz: e5a717dc5085ac14c02467595a2c1d484e3dcf74947982c2c00b0fadc0401205
3
+ metadata.gz: 4b331458dc7edd860f8c85ee68ba81ef4a7b18e43de0db41f3e8b5246cfd6f78
4
+ data.tar.gz: 250af210fc9adca4077cbe57ffb5490e5e8f0a0b74b018513db3bd81c2254763
5
5
  SHA512:
6
- metadata.gz: f76305302c2ad6ebfab41a8ac0de6f084fa3339bf66405d78a23af70242e4e6b01a239cc3f870ae36c360918e21fd0855f54b273d13699e7c43b8ed3286a3981
7
- data.tar.gz: bf0e01ca48f758e71bb632c72fd4bae90612d81dec6bdd08f7efcc84442daa8c45bd00df4e5507cf860c7f8c6def1b7836986544f40dd8b0fcee0d921a77e89e
6
+ metadata.gz: 638061fd42b4a70c18db00543eb70c1f830165b3b059ea14cda1d9b5d9cadfee69f5ff2365ba5b87f317646701d76ddc645333a5068801841bee725ce89b0d49
7
+ data.tar.gz: 64835b4b1e4a5c88e0457bc1338007f55bd8ff806c24d1596b15a6e1f206833af7331dfe1b0a233d9fbc793c6848a09f645e1b3b49a3bc8213e1b237e9727bf4
@@ -24,6 +24,10 @@ module Isomorfeus
24
24
  ObjectSpace.define_finalizer(self, self.class.close_browser(self))
25
25
  end
26
26
 
27
+ def close
28
+ @browser.close
29
+ end
30
+
27
31
  def devices
28
32
  ::Puppeteer::DEVICES
29
33
  end
@@ -39,7 +43,7 @@ module Isomorfeus
39
43
  def goto(uri, referer: nil, timeout: nil, wait_until: 'networkidle0')
40
44
  parsed_uri = parse_uri(uri)
41
45
  @response = @default_page.goto(parsed_uri.to_s, referer: referer, timeout: timeout, wait_until: wait_until)
42
- self
46
+ @default_page
43
47
  end
44
48
  alias_method :visit, :goto
45
49
 
@@ -89,7 +93,7 @@ module Isomorfeus
89
93
 
90
94
  def eval_ruby(ruby_source = '', &block)
91
95
  ruby_source = Isomorfeus::Puppetmaster.block_source_code(&block) if block_given?
92
- compiled_ruby = compile_ruby_source(ruby_source)
96
+ compiled_ruby = Isomorfeus::Puppetmaster.compile_ruby_source(ruby_source)
93
97
  res = self.evaluate "function(){ try { return #{compiled_ruby} } catch (e) { return { error: e.name, message: e.message, stack: e.stack }; }}"
94
98
  if res.is_a?(Hash) && res.key?('error') && res.key?('message') && res.key?('stack')
95
99
  e = RuntimeError.new("#{res['error']}: #{res['message']}")
@@ -101,7 +105,7 @@ module Isomorfeus
101
105
 
102
106
  def eval_with_opal(ruby_source = '', &block)
103
107
  ruby_source = Isomorfeus::Puppetmaster.block_source_code(&block) if block_given?
104
- compiled_ruby = compile_ruby_source(ruby_source)
108
+ compiled_ruby = Isomorfeus::Puppetmaster.compile_ruby_source(ruby_source)
105
109
  res = self.evaluate <<~JAVASCRIPT
106
110
  function(){
107
111
  if (typeof Opal === "undefined") {
@@ -1,3 +1,3 @@
1
1
  module Isomorfeus
2
- PUPPETMASTER_VERSION = '0.6.2'
2
+ PUPPETMASTER_VERSION = '0.6.3'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: isomorfeus-puppetmaster
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.2
4
+ version: 0.6.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jan Biedermann