isomorfeus-puppetmaster 0.6.14 → 0.6.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
    
        checksums.yaml
    CHANGED
    
    | 
         @@ -1,7 +1,7 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            ---
         
     | 
| 
       2 
2 
     | 
    
         
             
            SHA256:
         
     | 
| 
       3 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       4 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 3 
     | 
    
         
            +
              metadata.gz: 72e7c811306c9edf318a669c0d9fd04e1bbb8942be3b8520df0cc92460497851
         
     | 
| 
      
 4 
     | 
    
         
            +
              data.tar.gz: 4fc9006cdfde519a18beb248de3b142dbb7bb6d581a5a3b542ff0b4f6f9a7800
         
     | 
| 
       5 
5 
     | 
    
         
             
            SHA512:
         
     | 
| 
       6 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       7 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 6 
     | 
    
         
            +
              metadata.gz: 454f7f958754c678e4a2000fe9a6bbf39d8360f89190a64362eb07fafed56e9bcb295cc74ce93d67ba65b7d505400f6036316a8e4438cc5a2af5655f22622a23
         
     | 
| 
      
 7 
     | 
    
         
            +
              data.tar.gz: 296cabfcdcec71bc13232f3fa3a6bcc556295d46c7fec5d0cb672f8a44f6d041ab7b29fe30495c4463fe9af06e7a3fb255b52e82123e8d269bd991650738d40d
         
     | 
    
        data/README.md
    CHANGED
    
    | 
         @@ -3,9 +3,10 @@ 
     | 
|
| 
       3 
3 
     | 
    
         
             
              <br/>
         
     | 
| 
       4 
4 
     | 
    
         
             
            Isomorfeus Puppetmaster<br/>
         
     | 
| 
       5 
5 
     | 
    
         
             
            </h1>
         
     | 
| 
      
 6 
     | 
    
         
            +
             
     | 
| 
       6 
7 
     | 
    
         
             
            A framework for acceptance tests or simply running tests in a headless browser.
         
     | 
| 
       7 
8 
     | 
    
         
             
            Allows for writing javascript browser tests in pure ruby.
         
     | 
| 
       8 
     | 
    
         
            -
            It is tailored for Isomorfeus and using [puppeteer-ruby](https://github.com/YusukeIwaki/puppeteer-ruby) 
     | 
| 
      
 9 
     | 
    
         
            +
            It is tailored for Isomorfeus and using [puppeteer-ruby](https://github.com/YusukeIwaki/puppeteer-ruby)
         
     | 
| 
       9 
10 
     | 
    
         | 
| 
       10 
11 
     | 
    
         
             
            ### Community and Support
         
     | 
| 
       11 
12 
     | 
    
         
             
            At the [Isomorfeus Framework Project](https://isomorfeus.com)
         
     | 
| 
         @@ -88,7 +89,7 @@ page2.goto('/location') 
     | 
|
| 
       88 
89 
     | 
    
         | 
| 
       89 
90 
     | 
    
         
             
            For debugging:
         
     | 
| 
       90 
91 
     | 
    
         
             
            ```ruby
         
     | 
| 
       91 
     | 
    
         
            -
            page 
     | 
| 
      
 92 
     | 
    
         
            +
            page = visit('/', headless: false, devtools: true)
         
     | 
| 
       92 
93 
     | 
    
         
             
            ```
         
     | 
| 
       93 
94 
     | 
    
         
             
            This will close the current browser if the options for headless and devtools dont match, and open a new one with the supplied headless and devtools options.
         
     | 
| 
       94 
95 
     | 
    
         | 
| 
         @@ -28,11 +28,12 @@ module Isomorfeus 
     | 
|
| 
       28 
28 
     | 
    
         
             
                                Isomorfeus.store.clear! if Isomorfeus.store.respond_to?(:clear!)
         
     | 
| 
       29 
29 
     | 
    
         
             
                              end
         
     | 
| 
       30 
30 
     | 
    
         
             
                              result = TOPLEVEL_BINDING.eval(request_hash['code']) if request_hash['code']
         
     | 
| 
       31 
     | 
    
         
            -
                               
     | 
| 
      
 31 
     | 
    
         
            +
                              result = result.value if result.is_a?(Promise)
         
     | 
| 
      
 32 
     | 
    
         
            +
                              response = Rack::Response.new(Oj.dump({ 'result' => result }, circular: true),
         
     | 
| 
       32 
33 
     | 
    
         
             
                                                            200,
         
     | 
| 
       33 
34 
     | 
    
         
             
                                                            'Content-Type' => 'application/json')
         
     | 
| 
       34 
35 
     | 
    
         
             
                            rescue Exception => e
         
     | 
| 
       35 
     | 
    
         
            -
                              response = Rack::Response.new(Oj.dump({ 'error' => "#{e.class}: #{e.message}", 'backtrace' => e.backtrace 
     | 
| 
      
 36 
     | 
    
         
            +
                              response = Rack::Response.new(Oj.dump({ 'error' => "#{e.class}: #{e.message}", 'backtrace' => e.backtrace&.join("\n") }),
         
     | 
| 
       36 
37 
     | 
    
         
             
                                                            200,
         
     | 
| 
       37 
38 
     | 
    
         
             
                                                            'Content-Type' => 'application/json')
         
     | 
| 
       38 
39 
     | 
    
         
             
                            end
         
     | 
| 
         @@ -85,7 +85,7 @@ module Isomorfeus 
     | 
|
| 
       85 
85 
     | 
    
         
             
                                 http.post('/__executor__', Oj.dump(request_hash, mode: :strict))
         
     | 
| 
       86 
86 
     | 
    
         
             
                               end
         
     | 
| 
       87 
87 
     | 
    
         
             
                    if response.code == '200'
         
     | 
| 
       88 
     | 
    
         
            -
                      result_hash = Oj.load(response.body)
         
     | 
| 
      
 88 
     | 
    
         
            +
                      result_hash = Oj.load(response.body, circular: true)
         
     | 
| 
       89 
89 
     | 
    
         
             
                      if result_hash.key?('error')
         
     | 
| 
       90 
90 
     | 
    
         
             
                        error = RuntimeError.new(result_hash['error'])
         
     | 
| 
       91 
91 
     | 
    
         
             
                        error.set_backtrace(result_hash['backtrace'])
         
     | 
| 
         @@ -5,6 +5,9 @@ require 'uri' 
     | 
|
| 
       5 
5 
     | 
    
         
             
            require 'net/http'
         
     | 
| 
       6 
6 
     | 
    
         
             
            require 'rack'
         
     | 
| 
       7 
7 
     | 
    
         
             
            require 'opal'
         
     | 
| 
      
 8 
     | 
    
         
            +
            opal_path = Gem::Specification.find_by_name('opal').full_gem_path
         
     | 
| 
      
 9 
     | 
    
         
            +
            promise_path = File.join(opal_path, 'stdlib', 'promise.rb')
         
     | 
| 
      
 10 
     | 
    
         
            +
            require promise_path
         
     | 
| 
       8 
11 
     | 
    
         
             
            require 'parser'
         
     | 
| 
       9 
12 
     | 
    
         | 
| 
       10 
13 
     | 
    
         
             
            # isomorfeus needs kwargs
         
     | 
    
        metadata
    CHANGED
    
    | 
         @@ -1,14 +1,14 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            --- !ruby/object:Gem::Specification
         
     | 
| 
       2 
2 
     | 
    
         
             
            name: isomorfeus-puppetmaster
         
     | 
| 
       3 
3 
     | 
    
         
             
            version: !ruby/object:Gem::Version
         
     | 
| 
       4 
     | 
    
         
            -
              version: 0.6. 
     | 
| 
      
 4 
     | 
    
         
            +
              version: 0.6.17
         
     | 
| 
       5 
5 
     | 
    
         
             
            platform: ruby
         
     | 
| 
       6 
6 
     | 
    
         
             
            authors:
         
     | 
| 
       7 
7 
     | 
    
         
             
            - Jan Biedermann
         
     | 
| 
       8 
8 
     | 
    
         
             
            autorequire:
         
     | 
| 
       9 
9 
     | 
    
         
             
            bindir: bin
         
     | 
| 
       10 
10 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       11 
     | 
    
         
            -
            date: 2022-08- 
     | 
| 
      
 11 
     | 
    
         
            +
            date: 2022-08-15 00:00:00.000000000 Z
         
     | 
| 
       12 
12 
     | 
    
         
             
            dependencies:
         
     | 
| 
       13 
13 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       14 
14 
     | 
    
         
             
              name: activesupport
         
     | 
| 
         @@ -92,14 +92,14 @@ dependencies: 
     | 
|
| 
       92 
92 
     | 
    
         
             
                requirements:
         
     | 
| 
       93 
93 
     | 
    
         
             
                - - "~>"
         
     | 
| 
       94 
94 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       95 
     | 
    
         
            -
                    version: 0. 
     | 
| 
      
 95 
     | 
    
         
            +
                    version: 0.42.0
         
     | 
| 
       96 
96 
     | 
    
         
             
              type: :runtime
         
     | 
| 
       97 
97 
     | 
    
         
             
              prerelease: false
         
     | 
| 
       98 
98 
     | 
    
         
             
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
       99 
99 
     | 
    
         
             
                requirements:
         
     | 
| 
       100 
100 
     | 
    
         
             
                - - "~>"
         
     | 
| 
       101 
101 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       102 
     | 
    
         
            -
                    version: 0. 
     | 
| 
      
 102 
     | 
    
         
            +
                    version: 0.42.0
         
     | 
| 
       103 
103 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       104 
104 
     | 
    
         
             
              name: tty-which
         
     | 
| 
       105 
105 
     | 
    
         
             
              requirement: !ruby/object:Gem::Requirement
         
     |