multi_test 1.1.0 → 2.0.0
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/CHANGELOG.md +25 -6
- data/LICENSE +18 -17
- data/README.md +9 -7
- data/lib/multi_test/assertion_library.rb +53 -53
- data/lib/multi_test/minitest_world.rb +2 -0
- data/lib/multi_test.rb +9 -26
- metadata +23 -24
- data/.github/CODEOWNERS +0 -1
- data/.github/settings.yml +0 -41
- data/.github/workflows/release-github.yml +0 -24
- data/.github/workflows/release-ruby.yml +0 -33
- data/.github/workflows/test-ruby.yml +0 -46
- data/.whitesource +0 -15
- data/Makefile +0 -7
- data/VERSION +0 -1
- data/multi_test.gemspec +0 -24
- data/test-all +0 -7
- data/test-gemfile +0 -32
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 0e623c6f7ee8f128b1d28ce1e825269dfaabfa3adabe2bca463919071bb82996
|
|
4
|
+
data.tar.gz: 8c567b38d8ddd22e3b64ba7f4622b0ac9c58aaed6bbeaba2bc292acec43d3743
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ec633811d0f32a35f2897edf7a9780770ba608cf6dbe993c0a8805b4d4fe31e4bf77c2bd13e13b9eb283e311f22e60e8069314c92994ce4950029c3aa788a1f2
|
|
7
|
+
data.tar.gz: d3f4c14210534e3744b221b90f835bf72ae79e79f645b11047720845d08a7a86f28538d98323a8ad031cda3f455a76bbdd5f047f2a8bf2493c8138eb9359237e
|
data/CHANGELOG.md
CHANGED
|
@@ -1,7 +1,25 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
All notable changes to this project will be documented in this file. For older versions see the [changelog archive](./CHANGELOG.old.md)
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
|
|
8
|
+
This file is intended to be modified using the [`changelog`](https://github.com/cucumber/changelog) command-line tool.
|
|
9
|
+
|
|
3
10
|
## [Unreleased]
|
|
4
11
|
|
|
12
|
+
## [2.0.0] - 2026-07-30
|
|
13
|
+
### Changed
|
|
14
|
+
- **BREAKING CHANGE**: Upped minimum ruby from `2.0` to `2.6`
|
|
15
|
+
- **BREAKING CHANGE**: Upped minimum `minitest` support from `2.0` to `5.0`
|
|
16
|
+
- **BREAKING CHANGE**: Removed all minitest autorun shims
|
|
17
|
+
- **BREAKING CHANGE**: Upped minimum `rspec` support from `1.0` to `2.0`
|
|
18
|
+
- Ran a full aggressive rubocop audit on code to refactor into more modern ruby style
|
|
19
|
+
|
|
20
|
+
### Fixed
|
|
21
|
+
- Partially fixed the local execution of tests by not complaining when test frameworks output boilerplate responses
|
|
22
|
+
|
|
5
23
|
## [1.1.0] - 2022-05-11
|
|
6
24
|
### Added
|
|
7
25
|
- `MultiTest.disable_autorun` is back again!
|
|
@@ -23,8 +41,8 @@ as reported in [#21](https://github.com/cucumber/multi_test/issues/21)
|
|
|
23
41
|
|
|
24
42
|
## [0.1.2]
|
|
25
43
|
### Changed
|
|
26
|
-
- Ensure that detecting
|
|
27
|
-
included. Ruby 2.2 removed minitest from standard library. (@tooky, @jmoody)
|
|
44
|
+
- Ensure that detecting assertion library doesn't fail if no test framework
|
|
45
|
+
included. Ruby `2.2` removed minitest from standard library. (@tooky, @jmoody)
|
|
28
46
|
|
|
29
47
|
## [0.1.1]
|
|
30
48
|
### Removed
|
|
@@ -32,7 +50,7 @@ included. Ruby 2.2 removed minitest from standard library. (@tooky, @jmoody)
|
|
|
32
50
|
|
|
33
51
|
## [0.1.0]
|
|
34
52
|
### Added
|
|
35
|
-
- Detect best available assertion library for cucumber (@tooky)
|
|
53
|
+
- Detect the best available assertion library for cucumber (@tooky)
|
|
36
54
|
|
|
37
55
|
## [0.0.3]
|
|
38
56
|
### Fixed
|
|
@@ -42,9 +60,10 @@ included. Ruby 2.2 removed minitest from standard library. (@tooky, @jmoody)
|
|
|
42
60
|
### Changed
|
|
43
61
|
- First gem release
|
|
44
62
|
|
|
45
|
-
[Unreleased]: https://github.com/cucumber/multi_test/compare/1.
|
|
46
|
-
[
|
|
47
|
-
[1.
|
|
63
|
+
[Unreleased]: https://github.com/cucumber/multi_test/compare/1.1.0..HEAD
|
|
64
|
+
[2.0.0]: https://github.com/cucumber/multi_test/compare/1.1.0..v2.0.0
|
|
65
|
+
[1.1.0]: https://github.com/cucumber/multi_test/compare/1.0.0..1.1.0
|
|
66
|
+
[1.0.0]: https://github.com/cucumber/multi_test/compare/v0.1.2..1.0.0
|
|
48
67
|
[0.1.2]: https://github.com/cucumber/multi_test/compare/v0.1.1...v0.1.2
|
|
49
68
|
[0.1.1]: https://github.com/cucumber/multi_test/compare/v0.1.0...v0.1.1
|
|
50
69
|
[0.1.0]: https://github.com/cucumber/multi_test/compare/v0.0.3...v0.1.0
|
data/LICENSE
CHANGED
|
@@ -1,20 +1,21 @@
|
|
|
1
|
-
|
|
1
|
+
MIT License
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
a copy of this software and associated documentation files (the
|
|
5
|
-
"Software"), to deal in the Software without restriction, including
|
|
6
|
-
without limitation the rights to use, copy, modify, merge, publish,
|
|
7
|
-
distribute, sublicense, and/or sell copies of the Software, and to
|
|
8
|
-
permit persons to whom the Software is furnished to do so, subject to
|
|
9
|
-
the following conditions:
|
|
3
|
+
Copyright (c) 2013 Cucumber Ltd and contributors
|
|
10
4
|
|
|
11
|
-
|
|
12
|
-
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
13
11
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
data/README.md
CHANGED
|
@@ -1,15 +1,17 @@
|
|
|
1
|
-
[](https://github.com/cucumber/multi_test/actions/workflows/test-ruby.yaml)
|
|
2
2
|
[](https://badge.fury.io/rb/multi_test)
|
|
3
3
|
|
|
4
|
-
This project gives you a uniform interface
|
|
5
|
-
loaded into
|
|
4
|
+
This project gives you a uniform interface for whatever testing library has been
|
|
5
|
+
loaded into your running Ruby process for Cucumber.
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
This is used _automatically_ within `cucumber-ruby` to discover and autoload your required assertion library
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
You can use it manually (But you should never need to) if you want to use the same assertion library as Cucumber
|
|
10
|
+
in your own code.
|
|
11
|
+
|
|
12
|
+
```ruby
|
|
11
13
|
require 'multi_test'
|
|
12
14
|
|
|
13
15
|
my_tests = Object.new
|
|
14
16
|
MultiTest.extend_with_best_assertion_library(my_tests)
|
|
15
|
-
|
|
17
|
+
```
|
|
@@ -1,73 +1,73 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
require 'multi_test/minitest_world'
|
|
2
4
|
|
|
3
5
|
module MultiTest
|
|
4
6
|
class AssertionLibrary
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
def initialize(requirer, extender)
|
|
10
|
-
@requirer = requirer
|
|
11
|
-
@extender = extender
|
|
12
|
-
end
|
|
13
|
-
|
|
14
|
-
def require?
|
|
15
|
-
begin
|
|
16
|
-
@requirer.call
|
|
17
|
-
true
|
|
18
|
-
rescue LoadError
|
|
19
|
-
false
|
|
7
|
+
class << self
|
|
8
|
+
def detect_best
|
|
9
|
+
available.detect(&:require?)
|
|
20
10
|
end
|
|
21
|
-
end
|
|
22
11
|
|
|
23
|
-
|
|
24
|
-
@extender.call(world)
|
|
25
|
-
end
|
|
12
|
+
private
|
|
26
13
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
14
|
+
def available
|
|
15
|
+
@available ||= [
|
|
16
|
+
rspec,
|
|
17
|
+
minitest,
|
|
18
|
+
test_unit,
|
|
19
|
+
# Null assertion library must come last to prevent exceptions if unable to load a test framework
|
|
20
|
+
null
|
|
21
|
+
]
|
|
22
|
+
end
|
|
35
23
|
|
|
36
|
-
|
|
37
|
-
|
|
24
|
+
# API is v2+
|
|
25
|
+
def rspec
|
|
38
26
|
AssertionLibrary.new(
|
|
39
27
|
proc { require 'rspec/expectations' },
|
|
40
28
|
proc { |object| object.extend(::RSpec::Matchers) }
|
|
41
|
-
)
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
require 'ostruct'
|
|
47
|
-
},
|
|
48
|
-
proc { |object|
|
|
49
|
-
options = OpenStruct.new(:diff_format => :unified, :context_lines => 3)
|
|
50
|
-
Spec::Expectations.differ = Spec::Expectations::Differs::Default.new(options)
|
|
51
|
-
object.extend(Spec::Matchers)
|
|
52
|
-
}
|
|
53
|
-
),
|
|
29
|
+
)
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
# API is v5+
|
|
33
|
+
def minitest
|
|
54
34
|
AssertionLibrary.new(
|
|
55
35
|
proc { require 'minitest/assertions' },
|
|
56
36
|
proc { |object| object.extend(MinitestWorld) }
|
|
57
|
-
)
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
37
|
+
)
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
# Test::Unit (Ruby standard); API is v1.8+
|
|
41
|
+
# From v2.1+ it became the `test-unit` gem
|
|
42
|
+
def test_unit
|
|
62
43
|
AssertionLibrary.new(
|
|
63
44
|
proc { require 'test/unit/assertions' },
|
|
64
45
|
proc { |object| object.extend(Test::Unit::Assertions) }
|
|
65
|
-
)
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
46
|
+
)
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
def null
|
|
50
|
+
AssertionLibrary.new(
|
|
51
|
+
proc {},
|
|
52
|
+
proc {}
|
|
53
|
+
)
|
|
54
|
+
end
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
def initialize(requirer, extender)
|
|
58
|
+
@requirer = requirer
|
|
59
|
+
@extender = extender
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
def require?
|
|
63
|
+
@requirer.call
|
|
64
|
+
true
|
|
65
|
+
rescue LoadError
|
|
66
|
+
false
|
|
67
|
+
end
|
|
68
|
+
|
|
69
|
+
def extend_world(world)
|
|
70
|
+
@extender.call(world)
|
|
70
71
|
end
|
|
71
72
|
end
|
|
72
73
|
end
|
|
73
|
-
|
data/lib/multi_test.rb
CHANGED
|
@@ -1,33 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require 'English'
|
|
1
4
|
require 'multi_test/assertion_library'
|
|
2
5
|
module MultiTest
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
+
class << self
|
|
7
|
+
# TODO: Remove in v3 (Targeting minispec and external gem removals first)
|
|
8
|
+
def disable_autorun
|
|
9
|
+
Test::Unit::Runner.module_eval('@@stop_auto_run = true', __FILE__, __LINE__) if defined?(Test::Unit::Runner)
|
|
6
10
|
end
|
|
7
11
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
def run(*)
|
|
11
|
-
# propagate the exit code from cucumber or another runner
|
|
12
|
-
case $!
|
|
13
|
-
when SystemExit
|
|
14
|
-
$!.status
|
|
15
|
-
else
|
|
16
|
-
true
|
|
17
|
-
end
|
|
18
|
-
end
|
|
19
|
-
end
|
|
20
|
-
|
|
21
|
-
if defined?(Minitest::Unit)
|
|
22
|
-
Minitest::Unit.class_eval do
|
|
23
|
-
def run(*)
|
|
24
|
-
end
|
|
25
|
-
end
|
|
26
|
-
end
|
|
12
|
+
def extend_with_best_assertion_library(object)
|
|
13
|
+
AssertionLibrary.detect_best.extend_world(object)
|
|
27
14
|
end
|
|
28
15
|
end
|
|
29
|
-
|
|
30
|
-
def self.extend_with_best_assertion_library(object)
|
|
31
|
-
AssertionLibrary.detect_best.extend_world(object)
|
|
32
|
-
end
|
|
33
16
|
end
|
metadata
CHANGED
|
@@ -1,61 +1,60 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: multi_test
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version:
|
|
4
|
+
version: 2.0.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Matt Wynne
|
|
8
8
|
- Steve Tooke
|
|
9
|
-
autorequire:
|
|
10
9
|
bindir: bin
|
|
11
10
|
cert_chain: []
|
|
12
|
-
date:
|
|
13
|
-
dependencies:
|
|
14
|
-
|
|
11
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
12
|
+
dependencies:
|
|
13
|
+
- !ruby/object:Gem::Dependency
|
|
14
|
+
name: rubocop
|
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
|
16
|
+
requirements:
|
|
17
|
+
- - "~>"
|
|
18
|
+
- !ruby/object:Gem::Version
|
|
19
|
+
version: 1.88.2
|
|
20
|
+
type: :development
|
|
21
|
+
prerelease: false
|
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
23
|
+
requirements:
|
|
24
|
+
- - "~>"
|
|
25
|
+
- !ruby/object:Gem::Version
|
|
26
|
+
version: 1.88.2
|
|
27
|
+
description: Wafer thin gem to help control rogue test/unit/autorun requires
|
|
15
28
|
email: cukes@googlegroups.com
|
|
16
29
|
executables: []
|
|
17
30
|
extensions: []
|
|
18
31
|
extra_rdoc_files: []
|
|
19
32
|
files:
|
|
20
|
-
- ".github/CODEOWNERS"
|
|
21
|
-
- ".github/settings.yml"
|
|
22
|
-
- ".github/workflows/release-github.yml"
|
|
23
|
-
- ".github/workflows/release-ruby.yml"
|
|
24
|
-
- ".github/workflows/test-ruby.yml"
|
|
25
|
-
- ".whitesource"
|
|
26
33
|
- CHANGELOG.md
|
|
27
34
|
- LICENSE
|
|
28
|
-
- Makefile
|
|
29
35
|
- README.md
|
|
30
|
-
- VERSION
|
|
31
36
|
- lib/multi_test.rb
|
|
32
37
|
- lib/multi_test/assertion_library.rb
|
|
33
38
|
- lib/multi_test/minitest_world.rb
|
|
34
|
-
|
|
35
|
-
- test-all
|
|
36
|
-
- test-gemfile
|
|
37
|
-
homepage: http://cukes.info
|
|
39
|
+
homepage: https://cucumber.io/
|
|
38
40
|
licenses:
|
|
39
41
|
- MIT
|
|
40
42
|
metadata: {}
|
|
41
|
-
|
|
42
|
-
rdoc_options:
|
|
43
|
-
- "--charset=UTF-8"
|
|
43
|
+
rdoc_options: []
|
|
44
44
|
require_paths:
|
|
45
45
|
- lib
|
|
46
46
|
required_ruby_version: !ruby/object:Gem::Requirement
|
|
47
47
|
requirements:
|
|
48
48
|
- - ">="
|
|
49
49
|
- !ruby/object:Gem::Version
|
|
50
|
-
version: '2.
|
|
50
|
+
version: '2.6'
|
|
51
51
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
52
52
|
requirements:
|
|
53
53
|
- - ">="
|
|
54
54
|
- !ruby/object:Gem::Version
|
|
55
55
|
version: 1.6.1
|
|
56
56
|
requirements: []
|
|
57
|
-
rubygems_version:
|
|
58
|
-
signing_key:
|
|
57
|
+
rubygems_version: 4.0.16
|
|
59
58
|
specification_version: 4
|
|
60
|
-
summary: multi-test-
|
|
59
|
+
summary: multi-test-2.0.0
|
|
61
60
|
test_files: []
|
data/.github/CODEOWNERS
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.github/settings.yml @cucumber/settings
|
data/.github/settings.yml
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
_extends: .github
|
|
2
|
-
|
|
3
|
-
branches:
|
|
4
|
-
- name: main
|
|
5
|
-
protection:
|
|
6
|
-
required_pull_request_reviews: null
|
|
7
|
-
required_status_checks: null
|
|
8
|
-
restrictions: null
|
|
9
|
-
enforce_admins: true
|
|
10
|
-
# https://github.com/cucumber/multi_test
|
|
11
|
-
# https://github.com/cucumber/multi_test
|
|
12
|
-
# # https://docs.github.com/en/rest/reference/repos#update-branch-protection
|
|
13
|
-
# # Branch Protection settings.
|
|
14
|
-
# protection:
|
|
15
|
-
# # Required. Require at least one approving review on a pull request, before merging. Set to null to disable.
|
|
16
|
-
# required_pull_request_reviews:
|
|
17
|
-
# # The number of approvals required. (1-6)
|
|
18
|
-
# required_approving_review_count: 0
|
|
19
|
-
# # Dismiss approved reviews automatically when a new commit is pushed.
|
|
20
|
-
# dismiss_stale_reviews: true
|
|
21
|
-
# # Blocks merge until code owners have reviewed.
|
|
22
|
-
# require_code_owner_reviews: true
|
|
23
|
-
# # Specify which users and teams can dismiss pull request reviews. Pass an empty dismissal_restrictions object to disable. User and team dismissal_restrictions are only available for organization-owned repositories. Omit this parameter for personal repositories.
|
|
24
|
-
# dismissal_restrictions:
|
|
25
|
-
# users: []
|
|
26
|
-
# teams: []
|
|
27
|
-
# # Required. Require status checks to pass before merging. Set to null to disable
|
|
28
|
-
# required_status_checks:
|
|
29
|
-
# # Required. Require branches to be up to date before merging.
|
|
30
|
-
# strict: true
|
|
31
|
-
# # Required. The list of status checks to require in order to merge into this branch
|
|
32
|
-
# contexts: []
|
|
33
|
-
# # Required. Enforce all configured restrictions for administrators. Set to true to enforce required status checks for repository administrators. Set to null to disable.
|
|
34
|
-
# enforce_admins: true
|
|
35
|
-
# # Prevent merge commits from being pushed to matching branches
|
|
36
|
-
# required_linear_history: true
|
|
37
|
-
# # Required. Restrict who can push to this branch. Team and user restrictions are only available for organization-owned repositories. Set to null to disable.
|
|
38
|
-
# restrictions:
|
|
39
|
-
# apps: []
|
|
40
|
-
# users: []
|
|
41
|
-
# teams: []
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
name: Release on github
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches:
|
|
6
|
-
- release/*
|
|
7
|
-
|
|
8
|
-
jobs:
|
|
9
|
-
pre-release-check:
|
|
10
|
-
uses: cucumber/.github/.github/workflows/prerelease-checks.yml@main
|
|
11
|
-
|
|
12
|
-
create-github-release:
|
|
13
|
-
name: Create Git tag and GitHub Release
|
|
14
|
-
needs: [pre-release-check]
|
|
15
|
-
runs-on: ubuntu-latest
|
|
16
|
-
environment: Release
|
|
17
|
-
permissions:
|
|
18
|
-
contents: write
|
|
19
|
-
|
|
20
|
-
steps:
|
|
21
|
-
- uses: actions/checkout@v3
|
|
22
|
-
- uses: cucumber/action-create-github-release@v1.1.0
|
|
23
|
-
with:
|
|
24
|
-
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
name: Release ruby gem
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches:
|
|
6
|
-
- release/*
|
|
7
|
-
|
|
8
|
-
jobs:
|
|
9
|
-
pre-release-check:
|
|
10
|
-
uses: cucumber/.github/.github/workflows/prerelease-checks.yml@main
|
|
11
|
-
|
|
12
|
-
test-ruby:
|
|
13
|
-
uses: ./.github/workflows/test-ruby.yml
|
|
14
|
-
|
|
15
|
-
publish-rubygem:
|
|
16
|
-
name: Publish Ruby Gem
|
|
17
|
-
needs: [pre-release-check, test-ruby]
|
|
18
|
-
runs-on: ubuntu-latest
|
|
19
|
-
environment: Release
|
|
20
|
-
|
|
21
|
-
steps:
|
|
22
|
-
- uses: actions/checkout@v3
|
|
23
|
-
|
|
24
|
-
- name: Set up Ruby
|
|
25
|
-
uses: ruby/setup-ruby@v1
|
|
26
|
-
with:
|
|
27
|
-
ruby-version: "3.0"
|
|
28
|
-
bundler-cache: true
|
|
29
|
-
|
|
30
|
-
- name: Publish ruby gem
|
|
31
|
-
uses: cucumber/action-publish-rubygem@v1.0.0
|
|
32
|
-
with:
|
|
33
|
-
rubygems_api_key: ${{ secrets.RUBYGEMS_API_KEY }}
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
name: Test
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches:
|
|
6
|
-
- main
|
|
7
|
-
pull_request:
|
|
8
|
-
branches:
|
|
9
|
-
- main
|
|
10
|
-
schedule:
|
|
11
|
-
- cron: "0 0 * * *"
|
|
12
|
-
workflow_call:
|
|
13
|
-
|
|
14
|
-
jobs:
|
|
15
|
-
test:
|
|
16
|
-
strategy:
|
|
17
|
-
fail-fast: false
|
|
18
|
-
matrix:
|
|
19
|
-
os: [ubuntu-latest]
|
|
20
|
-
ruby: ["2.6", "2.7", "3.0", "3.1"]
|
|
21
|
-
gemfile: # These are duplicated from the test/gemfiles folder
|
|
22
|
-
- activesupport-4
|
|
23
|
-
- activesupport-5
|
|
24
|
-
- minitest-4
|
|
25
|
-
- minitest-5
|
|
26
|
-
- plain-ruby
|
|
27
|
-
- rspec-1
|
|
28
|
-
- rspec-2
|
|
29
|
-
- rspec-3
|
|
30
|
-
- test-unit-2
|
|
31
|
-
- test-unit-3
|
|
32
|
-
|
|
33
|
-
runs-on: ${{ matrix.os }}
|
|
34
|
-
steps:
|
|
35
|
-
- uses: actions/checkout@v3
|
|
36
|
-
|
|
37
|
-
- name: Set up Ruby
|
|
38
|
-
uses: ruby/setup-ruby@v1
|
|
39
|
-
with:
|
|
40
|
-
ruby-version: ${{ matrix.ruby }}
|
|
41
|
-
bundler-cache: false
|
|
42
|
-
|
|
43
|
-
- name: Run test scenarios
|
|
44
|
-
run: |
|
|
45
|
-
./test-gemfile test/gemfiles/${{ matrix.gemfile }}
|
|
46
|
-
shell: bash
|
data/.whitesource
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"scanSettings": {
|
|
3
|
-
"configMode": "AUTO",
|
|
4
|
-
"configExternalURL": "",
|
|
5
|
-
"projectToken": "",
|
|
6
|
-
"baseBranches": []
|
|
7
|
-
},
|
|
8
|
-
"checkRunSettings": {
|
|
9
|
-
"vulnerableCheckRunConclusionLevel": "failure",
|
|
10
|
-
"displayMode": "diff"
|
|
11
|
-
},
|
|
12
|
-
"issueSettings": {
|
|
13
|
-
"minSeverityLevel": "LOW"
|
|
14
|
-
}
|
|
15
|
-
}
|
data/Makefile
DELETED
data/VERSION
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
1.1.0
|
data/multi_test.gemspec
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
# -*- encoding: utf-8 -*-
|
|
2
|
-
$LOAD_PATH.unshift File.expand_path("../lib", __FILE__)
|
|
3
|
-
|
|
4
|
-
Gem::Specification.new do |s|
|
|
5
|
-
s.name = 'multi_test'
|
|
6
|
-
s.version = File.read(File.join(File.expand_path(__dir__),'VERSION'))
|
|
7
|
-
s.authors = ["Matt Wynne", "Steve Tooke"]
|
|
8
|
-
s.description = 'Wafter-thin gem to help control rogue test/unit/autorun requires'
|
|
9
|
-
s.summary = "multi-test-#{s.version}"
|
|
10
|
-
s.email = 'cukes@googlegroups.com'
|
|
11
|
-
s.license = 'MIT'
|
|
12
|
-
s.homepage = "http://cukes.info"
|
|
13
|
-
|
|
14
|
-
s.platform = Gem::Platform::RUBY
|
|
15
|
-
|
|
16
|
-
s.required_ruby_version = ">= 2.0"
|
|
17
|
-
s.required_rubygems_version = ">= 1.6.1"
|
|
18
|
-
s.files = `git ls-files`.split("\n").
|
|
19
|
-
reject { |path| path =~ /\.gitignore$/ }.
|
|
20
|
-
reject { |path| path =~ /^test\// }
|
|
21
|
-
s.test_files = `git ls-files -- {gemfiles,test}/*`.split("\n")
|
|
22
|
-
s.rdoc_options = ["--charset=UTF-8"]
|
|
23
|
-
s.require_path = "lib"
|
|
24
|
-
end
|
data/test-all
DELETED
data/test-gemfile
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
#!/bin/bash
|
|
2
|
-
|
|
3
|
-
set -e
|
|
4
|
-
|
|
5
|
-
GEMFILE_FOLDER=$1
|
|
6
|
-
GEMFILE=$GEMFILE_FOLDER/Gemfile
|
|
7
|
-
echo
|
|
8
|
-
echo $GEMFILE
|
|
9
|
-
echo
|
|
10
|
-
scenarios=$(cat $GEMFILE_FOLDER/scenarios)
|
|
11
|
-
|
|
12
|
-
PLATFORM="$(BUNDLE_GEMFILE=$GEMFILE bundle platform)"
|
|
13
|
-
if [[ "$PLATFORM" =~ "Your Ruby version is" ]]; then
|
|
14
|
-
echo "$PLATFORM"
|
|
15
|
-
echo
|
|
16
|
-
echo "Skipping."
|
|
17
|
-
exit 0
|
|
18
|
-
fi
|
|
19
|
-
|
|
20
|
-
for scenario in $scenarios; do
|
|
21
|
-
echo
|
|
22
|
-
echo $scenario
|
|
23
|
-
echo
|
|
24
|
-
scenario_path=test/scenarios/$scenario
|
|
25
|
-
BUNDLE_GEMFILE=$GEMFILE bundle install
|
|
26
|
-
output=$(BUNDLE_GEMFILE=$GEMFILE bundle exec ruby -I lib test/scenarios/$scenario)
|
|
27
|
-
if [[ ! -z $output ]]; then
|
|
28
|
-
echo "Expected output to be empty, but was:"
|
|
29
|
-
echo "$output"
|
|
30
|
-
exit 1
|
|
31
|
-
fi
|
|
32
|
-
done
|