test-unit 3.7.0 → 3.7.1

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: a8a9bb306ea3324be8482cb2ed868697810c9c6c60a77be17430e941be3b3c96
4
- data.tar.gz: a180a008c16229d6b02d46165f041a22550a427f5075e996c98687286ae25363
3
+ metadata.gz: 8054a56e88494ff692947613a7bda0b5ef80ebcd4b04c0f68d6bc88ded186afa
4
+ data.tar.gz: 73375671fb1624bb0dcbde4f646cdb06c53772472d4244ddc2372ce97784128c
5
5
  SHA512:
6
- metadata.gz: 42e6d7ec6118d08c8911074c2e8d45c1bbbbad471c96d22097482e7736c7044dcc1f67cf0cf3e39e2670204085d53d1d9945dc5bd3983975de647e525159e7fc
7
- data.tar.gz: 3d80d7aa02f75c5a1f958e4c92fa508ba54205100eae53565f79cb22f3c0b464009896d0c2cc457dbef478158d693d867b263fc1f76f9adf2ddd6da88f47b61e
6
+ metadata.gz: 890e48aeee3fea05c458e633e72928249a84668b6e23cb972aee31a3220864774fb7ff9c948ad27569477e9b6e7782572cfa0878ce814504c42799c427f3b912
7
+ data.tar.gz: 94ee139d45b567e892ef837aa0afb75fb03976f2c44146a090ec5e76a672d3cd565cb90a43dcfadde873579cde9234094d6c418db2866af6ce6ffb91fa28217a
data/doc/text/news.md CHANGED
@@ -1,5 +1,24 @@
1
1
  # News
2
2
 
3
+ ## 3.7.1 - 2025-11-03 {#version-3-7-1}
4
+
5
+ ### Improvements
6
+
7
+ * Used absolute path instead of relative path for autoload.
8
+ * GH-311
9
+ * GH-325
10
+ * Suggested by nicholas a. evans
11
+
12
+ * Improved compatibility with power_assert 3.0 on older rubies.
13
+ * GH-329
14
+ * GH-330
15
+ * Patch by Jean Boussier
16
+
17
+ ### Thanks
18
+
19
+ * nicholas a. evans
20
+ * Jean Boussier
21
+
3
22
  ## 3.7.0 - 2025-07-06 {#version-3-7-0}
4
23
 
5
24
  ### Fixes
@@ -12,6 +12,9 @@ require_relative 'diff'
12
12
  begin
13
13
  require 'power_assert'
14
14
  rescue LoadError, SyntaxError
15
+ if defined?(::PowerAssert)
16
+ ::Object.send(:remove_const, :PowerAssert)
17
+ end
15
18
  end
16
19
 
17
20
  module Test
@@ -166,6 +166,7 @@ module Test
166
166
  @debug_on_failure = false
167
167
  @gc_stress = false
168
168
  @test_suite_runner_class = TestSuiteRunner
169
+ @load_paths = []
169
170
  config_file = "test-unit.yml"
170
171
  if File.exist?(config_file)
171
172
  load_config(config_file)
@@ -362,7 +363,9 @@ module Test
362
363
 
363
364
  o.on("-I", "--load-path=DIR[#{File::PATH_SEPARATOR}DIR...]",
364
365
  "Appends directory list to $LOAD_PATH.") do |dirs|
365
- $LOAD_PATH.concat(dirs.split(File::PATH_SEPARATOR))
366
+ load_paths = dirs.split(File::PATH_SEPARATOR)
367
+ $LOAD_PATH.concat(load_paths)
368
+ @load_paths.concat(load_paths)
366
369
  end
367
370
 
368
371
  color_schemes = ColorScheme.all
@@ -495,6 +498,9 @@ module Test
495
498
  @runner_options[:listeners] << GCStressListener.new
496
499
  end
497
500
  @runner_options[:test_suite_runner_class] = @test_suite_runner_class
501
+ @runner_options[:load_paths] = @load_paths
502
+ @runner_options[:base_directory] = @base
503
+ @runner_options[:test_paths] = @to_run
498
504
  change_work_directory do
499
505
  runner.run(suite, @runner_options).passed?
500
506
  end
@@ -1,6 +1,9 @@
1
1
  begin
2
2
  require 'power_assert'
3
3
  rescue LoadError, SyntaxError
4
+ if defined?(::PowerAssert)
5
+ ::Object.send(:remove_const, :PowerAssert)
6
+ end
4
7
  end
5
8
 
6
9
  module Test
@@ -1,5 +1,5 @@
1
1
  module Test
2
2
  module Unit
3
- VERSION = "3.7.0"
3
+ VERSION = "3.7.1"
4
4
  end
5
5
  end
data/lib/test-unit.rb CHANGED
@@ -4,8 +4,8 @@ require_relative "test/unit/warning"
4
4
 
5
5
  module Test
6
6
  module Unit
7
- autoload :TestCase, "test/unit/testcase"
8
- autoload :AutoRunner, "test/unit/autorunner"
7
+ autoload :TestCase, "#{__dir__}/test/unit/testcase"
8
+ autoload :AutoRunner, "#{__dir__}/test/unit/autorunner"
9
9
  end
10
10
  end
11
11
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: test-unit
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.7.0
4
+ version: 3.7.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kouhei Sutou
@@ -130,7 +130,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
130
130
  - !ruby/object:Gem::Version
131
131
  version: '0'
132
132
  requirements: []
133
- rubygems_version: 3.6.7
133
+ rubygems_version: 3.6.9
134
134
  specification_version: 4
135
135
  summary: An xUnit family unit testing framework for Ruby.
136
136
  test_files: []