executable_mock 1.0.0 → 1.1.0

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: 89e54f80480d9ec55c308051dea7c922eedfc79d0a1e8f8a33e7437d72890a28
4
- data.tar.gz: 841ee2e10667111ff0b8ef3e40506b4960e17f408f139805140181884c66eb92
3
+ metadata.gz: 2003e0dc0ff7c27ee63eac3c4f917ec5fe0828de72b0276262ebc85321752268
4
+ data.tar.gz: 76d766f64749ec239e4720c71f73f467d8a289bd6925dc5b23ff60442c970bda
5
5
  SHA512:
6
- metadata.gz: f2085220dcf0c2e981ec4be0e30d5777fab09cd80a65d462737ec153c4f0aa29d67ddbb6ad2229281ad50c0c75ac9b88f25f74affb3b65d11dfbcca358e0f5c6
7
- data.tar.gz: d6b243b5cbc886e1badf5ba30d617e7c7d7ee335b9e1388ed7cf2a946bda4ac5b532360e13fe0d98217b71f1579d5d243a28e6bf3ff063dc6f7ba56dac673003
6
+ metadata.gz: 58349fb27fa5a067a4b192cb76199ca5d0e7a5d78d66726b3d72bb165563c8f87d7c695c431e98b1902bf286f62b7ef7fdf6554a0312b269fa7b18bac6494dbd
7
+ data.tar.gz: 58d4f62ce96bcdc5ee9dc37d519bd9922737ccda9cd483775d151f07e3198a921710c8a72928b7154e2e547ddf5d598410d351272d211bf843191892aaba4ced
@@ -31,7 +31,9 @@ class ExecutableMock
31
31
  @name = name
32
32
  @file_path = File.join(directory, name)
33
33
  @path_setup = %(PATH="#{directory}:$PATH")
34
- @call_error_log_file_path = Tempfile.new.path
34
+ call_error_log_file = Tempfile.new
35
+ call_error_log_file.close
36
+ @call_error_log_file_path = call_error_log_file.path
35
37
 
36
38
  write_executable
37
39
  register_self
@@ -78,12 +80,11 @@ class ExecutableMock
78
80
 
79
81
  def counter_cache_path
80
82
  @counter_cache_path ||= begin
81
- Tempfile.new.path.tap do |file_path|
82
- data = Marshal.dump(@mappings.transform_values { 0 })
83
- File.open(file_path, "w") do |file|
84
- file.write(data)
85
- end
86
- end
83
+ data = Marshal.dump(@mappings.transform_values { 0 })
84
+ Tempfile.new.tap do |file|
85
+ file.write(data)
86
+ file.close
87
+ end.path
87
88
  end
88
89
  end
89
90
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  class ExecutableMock
4
- VERSION = "1.0.0"
4
+ VERSION = "1.1.0"
5
5
  end
metadata CHANGED
@@ -1,16 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: executable_mock
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Christophe Maximin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-12-03 00:00:00.000000000 Z
11
+ date: 2018-12-06 00:00:00.000000000 Z
12
12
  dependencies: []
13
- description: PLACEHOLDER
13
+ description: Generate executable with predefined inputs/outputs
14
14
  email:
15
15
  - christophe.maximin@gmail.com
16
16
  executables: []
@@ -36,7 +36,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
36
36
  requirements:
37
37
  - - ">="
38
38
  - !ruby/object:Gem::Version
39
- version: '2.6'
39
+ version: '2.5'
40
40
  required_rubygems_version: !ruby/object:Gem::Requirement
41
41
  requirements:
42
42
  - - ">="
@@ -47,5 +47,5 @@ rubyforge_project:
47
47
  rubygems_version: 3.0.0.beta2
48
48
  signing_key:
49
49
  specification_version: 4
50
- summary: PLACEHOLDER
50
+ summary: Generate executable with predefined inputs/outputs
51
51
  test_files: []