Ruby_AppThwack 0.0.4 → 0.0.5
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 +4 -4
 - data/Ruby_AppThwack-0.0.4.gem +0 -0
 - data/lib/ruby_appthwack/commands/run.rb +3 -1
 - data/lib/ruby_appthwack/reports.rb +16 -15
 - data/lib/ruby_appthwack.rb +1 -1
 - metadata +3 -3
 - data/Ruby_AppThwack-0.0.2.gem +0 -0
 
    
        checksums.yaml
    CHANGED
    
    | 
         @@ -1,7 +1,7 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            ---
         
     | 
| 
       2 
2 
     | 
    
         
             
            SHA1:
         
     | 
| 
       3 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       4 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 3 
     | 
    
         
            +
              metadata.gz: bb3be23cfdfdb61928eec6f248d179dd2937f707
         
     | 
| 
      
 4 
     | 
    
         
            +
              data.tar.gz: b8f082d121a01efc7d8200bbfadc90c824cc21fe
         
     | 
| 
       5 
5 
     | 
    
         
             
            SHA512:
         
     | 
| 
       6 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       7 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 6 
     | 
    
         
            +
              metadata.gz: 82b4c85921e4c0c3b9e7c67a635739fba676ad04fe79700f02cf36f086ba897b7f31c784142be4936d081ed0b83e43f609b1c78c5c9e27e830e0c2ada6d04a8d
         
     | 
| 
      
 7 
     | 
    
         
            +
              data.tar.gz: 3fbb37a3afe86ffe64ba939bd9661c295637e362c5ee8ee921d3f9f908665efaf8fd93b7c34dc0242a7c4d3cf7455af7132935e9ba532bbe44e802615e93e85e
         
     | 
| 
         Binary file 
     | 
| 
         @@ -68,13 +68,15 @@ command :run do |c| 
     | 
|
| 
       68 
68 
     | 
    
         
             
                sleep 5
         
     | 
| 
       69 
69 
     | 
    
         | 
| 
       70 
70 
     | 
    
         
             
                print "\n"
         
     | 
| 
       71 
     | 
    
         
            -
             
     | 
| 
      
 71 
     | 
    
         
            +
             
     | 
| 
       72 
72 
     | 
    
         
             
                # wait for test to terminate
         
     | 
| 
       73 
73 
     | 
    
         
             
                until not AppThwack::API.test_running? options.proj_id, options.run_id or not options.wait
         
     | 
| 
       74 
74 
     | 
    
         
             
                  print "."
         
     | 
| 
       75 
75 
     | 
    
         
             
                  sleep 30
         
     | 
| 
       76 
76 
     | 
    
         
             
                end
         
     | 
| 
       77 
77 
     | 
    
         | 
| 
      
 78 
     | 
    
         
            +
                print "\n"
         
     | 
| 
      
 79 
     | 
    
         
            +
             
     | 
| 
       78 
80 
     | 
    
         
             
                # download the results and we should have waited
         
     | 
| 
       79 
81 
     | 
    
         
             
                if options.downloadresults and options.wait
         
     | 
| 
       80 
82 
     | 
    
         
             
                  zip = AppThwack::API.download_results options.proj_id, options.run_id
         
     | 
| 
         @@ -36,27 +36,28 @@ module AppThwack::Reports 
     | 
|
| 
       36 
36 
     | 
    
         
             
            				puts device
         
     | 
| 
       37 
37 
     | 
    
         | 
| 
       38 
38 
     | 
    
         
             
            				f = File.join(reports, f, intermediate_folders, 'raw_calabash_json_output.instrtxt')
         
     | 
| 
      
 39 
     | 
    
         
            +
            				if File.exists? f
         
     | 
| 
      
 40 
     | 
    
         
            +
            					features = []
         
     | 
| 
       39 
41 
     | 
    
         | 
| 
       40 
     | 
    
         
            -
             
     | 
| 
      
 42 
     | 
    
         
            +
            					# now we just add the device prefix to each feature name to make it unique
         
     | 
| 
      
 43 
     | 
    
         
            +
            					File.open(f, 'r') do |io|
         
     | 
| 
       41 
44 
     | 
    
         | 
| 
       42 
     | 
    
         
            -
             
     | 
| 
       43 
     | 
    
         
            -
            				File.open(f, 'r') do |io|
         
     | 
| 
      
 45 
     | 
    
         
            +
            						features = JSON.load(io)
         
     | 
| 
       44 
46 
     | 
    
         | 
| 
       45 
     | 
    
         
            -
             
     | 
| 
       46 
     | 
    
         
            -
             
     | 
| 
       47 
     | 
    
         
            -
             
     | 
| 
       48 
     | 
    
         
            -
             
     | 
| 
       49 
     | 
    
         
            -
             
     | 
| 
       50 
     | 
    
         
            -
            							 
     | 
| 
       51 
     | 
    
         
            -
            							features[i]['name'] = "#{features[i]['name']} on #{device}"
         
     | 
| 
      
 47 
     | 
    
         
            +
            						if not features.nil?
         
     | 
| 
      
 48 
     | 
    
         
            +
            							
         
     | 
| 
      
 49 
     | 
    
         
            +
            							features.each_index do |i|
         
     | 
| 
      
 50 
     | 
    
         
            +
            								# append the device name to the feature name
         
     | 
| 
      
 51 
     | 
    
         
            +
            								features[i]['name'] = "#{features[i]['name']} on #{device}"
         
     | 
| 
      
 52 
     | 
    
         
            +
            							end
         
     | 
| 
       52 
53 
     | 
    
         
             
            						end
         
     | 
| 
       53 
     | 
    
         
            -
            					end
         
     | 
| 
       54 
54 
     | 
    
         | 
| 
       55 
     | 
    
         
            -
             
     | 
| 
      
 55 
     | 
    
         
            +
            						Dir.mkdir dst if not Dir.exists? dst
         
     | 
| 
       56 
56 
     | 
    
         | 
| 
       57 
     | 
    
         
            -
             
     | 
| 
       58 
     | 
    
         
            -
             
     | 
| 
       59 
     | 
    
         
            -
             
     | 
| 
      
 57 
     | 
    
         
            +
            						# now write out the new file
         
     | 
| 
      
 58 
     | 
    
         
            +
            						File.open(File.join(dst, "#{Time.now.to_i}_#{folder_name}.json"), 'w') do |io|
         
     | 
| 
      
 59 
     | 
    
         
            +
            							JSON.dump(features, io) unless features.nil?
         
     | 
| 
      
 60 
     | 
    
         
            +
            						end
         
     | 
| 
       60 
61 
     | 
    
         
             
            					end
         
     | 
| 
       61 
62 
     | 
    
         
             
            				end
         
     | 
| 
       62 
63 
     | 
    
         
             
            			end
         
     | 
    
        data/lib/ruby_appthwack.rb
    CHANGED
    
    
    
        metadata
    CHANGED
    
    | 
         @@ -1,14 +1,14 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            --- !ruby/object:Gem::Specification
         
     | 
| 
       2 
2 
     | 
    
         
             
            name: Ruby_AppThwack
         
     | 
| 
       3 
3 
     | 
    
         
             
            version: !ruby/object:Gem::Version
         
     | 
| 
       4 
     | 
    
         
            -
              version: 0.0. 
     | 
| 
      
 4 
     | 
    
         
            +
              version: 0.0.5
         
     | 
| 
       5 
5 
     | 
    
         
             
            platform: ruby
         
     | 
| 
       6 
6 
     | 
    
         
             
            authors:
         
     | 
| 
       7 
7 
     | 
    
         
             
            - Sam Stewart
         
     | 
| 
       8 
8 
     | 
    
         
             
            autorequire: 
         
     | 
| 
       9 
9 
     | 
    
         
             
            bindir: bin
         
     | 
| 
       10 
10 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       11 
     | 
    
         
            -
            date: 2013-08- 
     | 
| 
      
 11 
     | 
    
         
            +
            date: 2013-08-22 00:00:00.000000000 Z
         
     | 
| 
       12 
12 
     | 
    
         
             
            dependencies:
         
     | 
| 
       13 
13 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       14 
14 
     | 
    
         
             
              name: commander
         
     | 
| 
         @@ -138,7 +138,7 @@ files: 
     | 
|
| 
       138 
138 
     | 
    
         
             
            - ./lib/ruby_appthwack.rb
         
     | 
| 
       139 
139 
     | 
    
         
             
            - ./LICENSE
         
     | 
| 
       140 
140 
     | 
    
         
             
            - ./README.md
         
     | 
| 
       141 
     | 
    
         
            -
            - ./Ruby_AppThwack-0.0. 
     | 
| 
      
 141 
     | 
    
         
            +
            - ./Ruby_AppThwack-0.0.4.gem
         
     | 
| 
       142 
142 
     | 
    
         
             
            - ./ruby_appthwack.gemspec
         
     | 
| 
       143 
143 
     | 
    
         
             
            - bin/appthwack
         
     | 
| 
       144 
144 
     | 
    
         
             
            homepage: https://github.com/samstewart/ruby_appthwack
         
     | 
    
        data/Ruby_AppThwack-0.0.2.gem
    DELETED
    
    | 
         Binary file 
     |