synvert-core 1.8.0 → 1.8.1

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: 00661750a3522a9983d5eec1f064f62bf0d335e05e3b2a9cb7bb7222b04e20a2
4
- data.tar.gz: 5a35b831ca678486f4a51db2ae8a57bed58617299a0c26c9cbc0c462351ffd3d
3
+ metadata.gz: 6007d28c9a4371057b72bfbd4e73c23163cf52c384e7cef0a3fcdcd71b384fcd
4
+ data.tar.gz: 5b43685d36948aaf52dd313fdf0e6198eefa73ff12813853d1f289577f58da07
5
5
  SHA512:
6
- metadata.gz: b18bcf0f9f344c2c8661d7e4edf1a4f768d67175f45b34d2bb37b321f38681840c29b8e9a0fa61ee295329909f3093de4b7703e6dec21066190336ee8ceb1b5a
7
- data.tar.gz: 0f334dc34d82d15235381f3a9be7651707b5a7a0e5614e29f48310407c70384ac6f1594f2b8643dc97577e0e55a4b6165f3174071e2887f424a76ed4d5f3b3cb
6
+ metadata.gz: bc762494a28bc325231e1903130fbd14056442646b463b2e336426e59830f2ee8216fb6caa29c50960fed82a75bc320d4196919b0bffb9ab2547674f19bc89ac
7
+ data.tar.gz: 60e6b882a9b039c42acecb27581fca198482eeef15628ac9123daf4e08dd0bc109ebff3a1e5c2c7ac62ad8fd4fc7e6fdf65871d83b98a3a90c32b71702ff4057
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # CHANGELOG
2
2
 
3
+ ## 1.8.1 (2022-09-17)
4
+
5
+ * Fix test snippet, return test results
6
+
3
7
  ## 1.8.0 (2022-09-17)
4
8
 
5
9
  * Rename config `path` to `root_path`
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- synvert-core (1.8.0)
4
+ synvert-core (1.8.1)
5
5
  activesupport (< 7.0.0)
6
6
  erubis
7
7
  node_mutation
@@ -41,7 +41,7 @@ module Synvert::Core
41
41
  # It finds specified files, for each file, it executes the block code, tests the original code,
42
42
  # then returns the actions.
43
43
  def test
44
- get_file_paths.each do |file_path|
44
+ get_file_paths.map do |file_path|
45
45
  test_file(file_path)
46
46
  end
47
47
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Synvert
4
4
  module Core
5
- VERSION = '1.8.0'
5
+ VERSION = '1.8.1'
6
6
  end
7
7
  end
@@ -205,7 +205,7 @@ module Synvert::Core
205
205
  assert post.valid?
206
206
  end
207
207
  EOS
208
- expect(Dir).to receive(:glob).with('./spec/**/*_spec.rb').and_return(['spec/models/post_spec.rb'])
208
+ expect(Dir).to receive(:glob).with('spec/**/*_spec.rb').and_return(['spec/models/post_spec.rb'])
209
209
  expect(File).to receive(:read).with('spec/models/post_spec.rb', encoding: 'UTF-8').and_return(input)
210
210
  expect(File).to receive(:write).with('spec/models/post_spec.rb', output)
211
211
  instance.process
@@ -230,7 +230,7 @@ module Synvert::Core
230
230
  config.include FactoryGirl::Syntax::Methods
231
231
  end
232
232
  EOS
233
- expect(Dir).to receive(:glob).with('./spec/spec_helper.rb').and_return(['spec/spec_helper.rb'])
233
+ expect(Dir).to receive(:glob).with('spec/spec_helper.rb').and_return(['spec/spec_helper.rb'])
234
234
  expect(File).to receive(:read).with('spec/spec_helper.rb', encoding: 'UTF-8').and_return(input)
235
235
  expect(File).not_to receive(:write).with('spec/spec_helper.rb', output)
236
236
  instance.process
@@ -257,7 +257,7 @@ module Synvert::Core
257
257
  assert post.valid?
258
258
  end
259
259
  EOS
260
- expect(Dir).to receive(:glob).with('./spec/**/*_spec.rb').and_return(['spec/models/post_spec.rb']).twice
260
+ expect(Dir).to receive(:glob).with('spec/**/*_spec.rb').and_return(['spec/models/post_spec.rb']).twice
261
261
  expect(File).to receive(:read).with('spec/models/post_spec.rb', encoding: 'UTF-8').and_return(input)
262
262
  expect(File).to receive(:write).with('spec/models/post_spec.rb', output)
263
263
  expect(File).to receive(:read).with('spec/models/post_spec.rb', encoding: 'UTF-8').and_return(output)
@@ -284,7 +284,7 @@ module Synvert::Core
284
284
  assert post.valid?
285
285
  end
286
286
  EOS
287
- expect(Dir).to receive(:glob).with('./spec/**/*_spec.rb').and_return(['spec/models/post_spec.rb'])
287
+ expect(Dir).to receive(:glob).with('spec/**/*_spec.rb').and_return(['spec/models/post_spec.rb'])
288
288
  expect(File).to receive(:read).with('spec/models/post_spec.rb', encoding: 'UTF-8').and_return(input)
289
289
  results = instance.test
290
290
  expect(results[0].file_path).to eq 'spec/models/post_spec.rb'
@@ -308,7 +308,7 @@ module Synvert::Core
308
308
  config.include FactoryGirl::Syntax::Methods
309
309
  end
310
310
  EOS
311
- expect(Dir).to receive(:glob).with('./spec/spec_helper.rb').and_return(['spec/spec_helper.rb'])
311
+ expect(Dir).to receive(:glob).with('spec/spec_helper.rb').and_return(['spec/spec_helper.rb'])
312
312
  expect(File).to receive(:read).with('spec/spec_helper.rb', encoding: 'UTF-8').and_return(input)
313
313
  result = instance.test
314
314
  expect(result[0].file_path).to eq 'spec/spec_helper.rb'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: synvert-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.0
4
+ version: 1.8.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Richard Huang