timecop-rspec 1.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 +7 -0
- checksums.yaml.gz.sig +0 -0
- data/.devcontainer/devcontainer.json +26 -0
- data/.env.local.example +3 -0
- data/.envrc +41 -0
- data/.github/FUNDING.yml +13 -0
- data/.github/dependabot.yml +12 -0
- data/.github/workflows/ancient.yml +77 -0
- data/.github/workflows/auto-assign.yml +21 -0
- data/.github/workflows/codeql-analysis.yml +70 -0
- data/.github/workflows/coverage.yml +126 -0
- data/.github/workflows/current.yml +85 -0
- data/.github/workflows/dependency-review.yml +20 -0
- data/.github/workflows/deps_locked.yml +75 -0
- data/.github/workflows/deps_unlocked.yml +84 -0
- data/.github/workflows/discord-notifier.yml +38 -0
- data/.github/workflows/heads.yml +84 -0
- data/.github/workflows/jruby.yml +75 -0
- data/.github/workflows/legacy.yml +67 -0
- data/.github/workflows/style.yml +64 -0
- data/.github/workflows/supported.yml +82 -0
- data/.github/workflows/truffle.yml +75 -0
- data/.github/workflows/unsupported.yml +75 -0
- data/.gitignore +45 -0
- data/.gitlab-ci.yml +44 -0
- data/.idea/.gitignore +8 -0
- data/.idea/GitLink.xml +6 -0
- data/.idea/misc.xml +4 -0
- data/.idea/modules.xml +8 -0
- data/.idea/timecop-rspec.iml +120 -0
- data/.idea/vcs.xml +6 -0
- data/.junie/TASK_NOTE.md +1 -0
- data/.junie/guidelines.md +139 -0
- data/.qlty/qlty.toml +79 -0
- data/.rspec +8 -0
- data/.rubocop.yml +15 -0
- data/.rubocop_gradual.lock +76 -0
- data/.simplecov +11 -0
- data/.tool-versions +1 -0
- data/.yard_gfm_support.rb +22 -0
- data/.yardopts +11 -0
- data/Appraisal.root.gemfile +12 -0
- data/Appraisals +104 -0
- data/CHANGELOG.md +27 -0
- data/CITATION.cff +20 -0
- data/CNAME +1 -0
- data/CODE_OF_CONDUCT.md +134 -0
- data/CONTRIBUTING.md +145 -0
- data/Gemfile +38 -0
- data/Gemfile.lock +315 -0
- data/LICENSE.txt +22 -0
- data/README.md +563 -0
- data/REEK +0 -0
- data/RUBOCOP.md +71 -0
- data/Rakefile +287 -0
- data/SECURITY.md +21 -0
- data/bin/appraisal +16 -0
- data/bin/bundle-audit +16 -0
- data/bin/bundler-audit +16 -0
- data/bin/code_climate_reek +16 -0
- data/bin/coderay +16 -0
- data/bin/console +38 -0
- data/bin/erb +16 -0
- data/bin/gem_checksums +16 -0
- data/bin/htmldiff +16 -0
- data/bin/irb +16 -0
- data/bin/kramdown +16 -0
- data/bin/ldiff +16 -0
- data/bin/nokogiri +16 -0
- data/bin/pry +16 -0
- data/bin/racc +16 -0
- data/bin/rake +16 -0
- data/bin/rdbg +16 -0
- data/bin/rdoc +16 -0
- data/bin/reek +16 -0
- data/bin/ri +16 -0
- data/bin/rspec +16 -0
- data/bin/rubocop +16 -0
- data/bin/rubocop-gradual +16 -0
- data/bin/ruby-parse +16 -0
- data/bin/ruby-rewrite +16 -0
- data/bin/setup +33 -0
- data/bin/standardrb +16 -0
- data/bin/thor +16 -0
- data/bin/yard +16 -0
- data/bin/yard-junk +16 -0
- data/bin/yardoc +16 -0
- data/bin/yri +16 -0
- data/certs/pboling.pem +27 -0
- data/checksums/timecop-rspec-1.0.0.gem.sha256 +1 -0
- data/checksums/timecop-rspec-1.0.0.gem.sha512 +1 -0
- data/docs/Timecop/Rspec/ExampleDecorator.html +626 -0
- data/docs/Timecop/Rspec/SequentialTimeMachine.html +338 -0
- data/docs/Timecop/Rspec/TimeMachine.html +357 -0
- data/docs/Timecop/Rspec/TravelLog.html +440 -0
- data/docs/Timecop/Rspec/Traveler.html +353 -0
- data/docs/Timecop/Rspec/Version.html +154 -0
- data/docs/Timecop/Rspec.html +474 -0
- data/docs/Timecop.html +149 -0
- data/docs/_index.html +218 -0
- data/docs/class_list.html +54 -0
- data/docs/css/common.css +1 -0
- data/docs/css/full_list.css +58 -0
- data/docs/css/style.css +503 -0
- data/docs/file.CHANGELOG.html +99 -0
- data/docs/file.CITATION.html +92 -0
- data/docs/file.CODE_OF_CONDUCT.html +201 -0
- data/docs/file.CONTRIBUTING.html +220 -0
- data/docs/file.LICENSE.html +70 -0
- data/docs/file.README.html +523 -0
- data/docs/file.REEK.html +71 -0
- data/docs/file.RUBOCOP.html +171 -0
- data/docs/file.SECURITY.html +101 -0
- data/docs/file.rspec.html +109 -0
- data/docs/file.timecop.html +72 -0
- data/docs/file_list.html +109 -0
- data/docs/frames.html +22 -0
- data/docs/index.html +523 -0
- data/docs/js/app.js +344 -0
- data/docs/js/full_list.js +242 -0
- data/docs/js/jquery.js +4 -0
- data/docs/method_list.html +198 -0
- data/docs/top-level-namespace.html +110 -0
- data/gemfiles/audit.gemfile +10 -0
- data/gemfiles/coverage.gemfile +10 -0
- data/gemfiles/current.gemfile +8 -0
- data/gemfiles/deps_unlocked.gemfile +13 -0
- data/gemfiles/head.gemfile +9 -0
- data/gemfiles/modular/audit.gemfile +5 -0
- data/gemfiles/modular/coverage.gemfile +6 -0
- data/gemfiles/modular/documentation.gemfile +11 -0
- data/gemfiles/modular/style.gemfile +14 -0
- data/gemfiles/ruby_2_3.gemfile +5 -0
- data/gemfiles/ruby_2_4.gemfile +5 -0
- data/gemfiles/ruby_2_5.gemfile +5 -0
- data/gemfiles/ruby_2_6.gemfile +8 -0
- data/gemfiles/ruby_2_7.gemfile +8 -0
- data/gemfiles/ruby_3_0.gemfile +8 -0
- data/gemfiles/ruby_3_1.gemfile +8 -0
- data/gemfiles/ruby_3_2.gemfile +8 -0
- data/gemfiles/ruby_3_3.gemfile +8 -0
- data/gemfiles/style.gemfile +10 -0
- data/lib/timecop/rspec/example_decorator.rb +100 -0
- data/lib/timecop/rspec/sequential_time_machine.rb +80 -0
- data/lib/timecop/rspec/time_machine.rb +58 -0
- data/lib/timecop/rspec/travel_log.rb +103 -0
- data/lib/timecop/rspec/traveler.rb +68 -0
- data/lib/timecop/rspec/version.rb +37 -0
- data/lib/timecop/rspec.rb +78 -0
- data/sig/timecop/rspec.rbs +40 -0
- data/sig/timecop.rbs +2 -0
- data/timecop-rspec.gemspec +146 -0
- data.tar.gz.sig +2 -0
- metadata +434 -0
- metadata.gz.sig +0 -0
@@ -0,0 +1,38 @@
|
|
1
|
+
name: Discord Notify
|
2
|
+
|
3
|
+
on:
|
4
|
+
check_run:
|
5
|
+
types: [completed]
|
6
|
+
discussion:
|
7
|
+
types: [ created ]
|
8
|
+
discussion_comment:
|
9
|
+
types: [ created ]
|
10
|
+
fork:
|
11
|
+
gollum:
|
12
|
+
issues:
|
13
|
+
types: [ opened ]
|
14
|
+
issue_comment:
|
15
|
+
types: [ created ]
|
16
|
+
pull_request:
|
17
|
+
types: [ opened, reopened, closed ]
|
18
|
+
release:
|
19
|
+
types: [ published ]
|
20
|
+
watch:
|
21
|
+
types: [ started ]
|
22
|
+
|
23
|
+
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
24
|
+
jobs:
|
25
|
+
# This workflow contains a single job called "build"
|
26
|
+
notify:
|
27
|
+
# The type of runner that the job will run on
|
28
|
+
runs-on: ubuntu-latest
|
29
|
+
|
30
|
+
# Steps represent a sequence of tasks that will be executed as part of the job
|
31
|
+
steps:
|
32
|
+
- name: Actions Status Discord
|
33
|
+
uses: sarisia/actions-status-discord@v1
|
34
|
+
if: always()
|
35
|
+
with:
|
36
|
+
webhook: ${{ secrets.DISCORD_WEBHOOK }}
|
37
|
+
status: ${{ job.status }}
|
38
|
+
username: GitHub Actions
|
@@ -0,0 +1,84 @@
|
|
1
|
+
name: Heads
|
2
|
+
|
3
|
+
env:
|
4
|
+
K_SOUP_COV_DO: false
|
5
|
+
|
6
|
+
on:
|
7
|
+
push:
|
8
|
+
branches:
|
9
|
+
- 'main'
|
10
|
+
tags:
|
11
|
+
- '!*' # Do not execute on tags
|
12
|
+
pull_request:
|
13
|
+
branches:
|
14
|
+
- '*'
|
15
|
+
# Allow manually triggering the workflow.
|
16
|
+
workflow_dispatch:
|
17
|
+
|
18
|
+
permissions:
|
19
|
+
contents: read
|
20
|
+
|
21
|
+
# Cancels all previous workflow runs for the same branch that have not yet completed.
|
22
|
+
concurrency:
|
23
|
+
# The concurrency group contains the workflow name and the branch name.
|
24
|
+
group: "${{ github.workflow }}-${{ github.ref }}"
|
25
|
+
cancel-in-progress: true
|
26
|
+
|
27
|
+
jobs:
|
28
|
+
test:
|
29
|
+
name: Specs ${{ matrix.ruby }}@${{ matrix.appraisal }}${{ matrix.name_extra || '' }}
|
30
|
+
if: "!contains(github.event.commits[0].message, '[ci skip]') && !contains(github.event.commits[0].message, '[skip ci]')"
|
31
|
+
runs-on: ubuntu-latest
|
32
|
+
continue-on-error: ${{ matrix.experimental || endsWith(matrix.ruby, 'head') }}
|
33
|
+
env: # $BUNDLE_GEMFILE must be set at job level, so it is set for all steps
|
34
|
+
BUNDLE_GEMFILE: ${{ github.workspace }}/${{ matrix.gemfile }}.gemfile
|
35
|
+
strategy:
|
36
|
+
fail-fast: true
|
37
|
+
matrix:
|
38
|
+
include:
|
39
|
+
# NOTE: Heads use default rubygems / bundler; their defaults are custom, unreleased, and from the future!
|
40
|
+
# ruby-head
|
41
|
+
- ruby: "ruby-head"
|
42
|
+
appraisal: "head"
|
43
|
+
exec_cmd: "rake test"
|
44
|
+
gemfile: "Appraisal.root"
|
45
|
+
rubygems: default
|
46
|
+
bundler: default
|
47
|
+
|
48
|
+
# # truffleruby-head
|
49
|
+
# - ruby: "truffleruby-head"
|
50
|
+
# appraisal: "head"
|
51
|
+
# exec_cmd: "rake test"
|
52
|
+
# gemfile: "Appraisal.root"
|
53
|
+
# rubygems: default
|
54
|
+
# bundler: default
|
55
|
+
|
56
|
+
# jruby-head
|
57
|
+
- ruby: "jruby-head"
|
58
|
+
appraisal: "head"
|
59
|
+
exec_cmd: "rake test"
|
60
|
+
gemfile: "Appraisal.root"
|
61
|
+
rubygems: default
|
62
|
+
bundler: default
|
63
|
+
|
64
|
+
steps:
|
65
|
+
- name: Checkout
|
66
|
+
uses: actions/checkout@v5
|
67
|
+
|
68
|
+
- name: Setup Ruby & RubyGems
|
69
|
+
uses: ruby/setup-ruby@v1
|
70
|
+
with:
|
71
|
+
ruby-version: ${{ matrix.ruby }}
|
72
|
+
rubygems: ${{ matrix.rubygems }}
|
73
|
+
bundler: ${{ matrix.bundler }}
|
74
|
+
bundler-cache: false
|
75
|
+
|
76
|
+
# Raw `bundle` will use the BUNDLE_GEMFILE set to matrix.gemfile (i.e. Appraisal.root)
|
77
|
+
# We need to do this first to get appraisal installed.
|
78
|
+
# NOTE: This does not use the main Gemfile at all.
|
79
|
+
- name: Install Root Appraisal
|
80
|
+
run: bundle
|
81
|
+
- name: Appraisal for ${{ matrix.ruby }}@${{ matrix.appraisal }}
|
82
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle
|
83
|
+
- name: Tests for ${{ matrix.ruby }}@${{ matrix.appraisal }} via ${{ matrix.exec_cmd }}
|
84
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle exec ${{ matrix.exec_cmd }}
|
@@ -0,0 +1,75 @@
|
|
1
|
+
name: JRuby
|
2
|
+
|
3
|
+
env:
|
4
|
+
K_SOUP_COV_DO: false
|
5
|
+
|
6
|
+
on:
|
7
|
+
push:
|
8
|
+
branches:
|
9
|
+
- 'main'
|
10
|
+
tags:
|
11
|
+
- '!*' # Do not execute on tags
|
12
|
+
pull_request:
|
13
|
+
branches:
|
14
|
+
- '*'
|
15
|
+
# Allow manually triggering the workflow.
|
16
|
+
workflow_dispatch:
|
17
|
+
|
18
|
+
permissions:
|
19
|
+
contents: read
|
20
|
+
|
21
|
+
# Cancels all previous workflow runs for the same branch that have not yet completed.
|
22
|
+
concurrency:
|
23
|
+
# The concurrency group contains the workflow name and the branch name.
|
24
|
+
group: "${{ github.workflow }}-${{ github.ref }}"
|
25
|
+
cancel-in-progress: true
|
26
|
+
|
27
|
+
jobs:
|
28
|
+
test:
|
29
|
+
name: Specs ${{ matrix.ruby }} ${{ matrix.appraisal }}${{ matrix.name_extra || '' }}
|
30
|
+
if: "!contains(github.event.commits[0].message, '[ci skip]') && !contains(github.event.commits[0].message, '[skip ci]')"
|
31
|
+
runs-on: ubuntu-22.04
|
32
|
+
continue-on-error: ${{ matrix.experimental || endsWith(matrix.ruby, 'head') }}
|
33
|
+
env: # $BUNDLE_GEMFILE must be set at job level, so it is set for all steps
|
34
|
+
BUNDLE_GEMFILE: ${{ github.workspace }}/${{ matrix.gemfile }}.gemfile
|
35
|
+
strategy:
|
36
|
+
matrix:
|
37
|
+
include:
|
38
|
+
# TODO: truffleruby does not support upgrading rubygems; VALIDATE ASSUMPTION that same applies to JRuby
|
39
|
+
# jruby-9.3 (targets Ruby 2.6 compatibility)
|
40
|
+
- ruby: "jruby-9.3"
|
41
|
+
appraisal: "ruby-2-6"
|
42
|
+
exec_cmd: "rake test"
|
43
|
+
gemfile: "Appraisal.root"
|
44
|
+
rubygems: default
|
45
|
+
bundler: default
|
46
|
+
|
47
|
+
# jruby-9.4 (targets Ruby 3.1 compatibility)
|
48
|
+
- ruby: "jruby-9.4"
|
49
|
+
appraisal: "ruby-3-1"
|
50
|
+
exec_cmd: "rake test"
|
51
|
+
gemfile: "Appraisal.root"
|
52
|
+
rubygems: default
|
53
|
+
bundler: default
|
54
|
+
|
55
|
+
steps:
|
56
|
+
- name: Checkout
|
57
|
+
uses: actions/checkout@v5
|
58
|
+
|
59
|
+
- name: Setup Ruby & RubyGems
|
60
|
+
uses: ruby/setup-ruby@v1
|
61
|
+
with:
|
62
|
+
ruby-version: ${{ matrix.ruby }}
|
63
|
+
rubygems: ${{ matrix.rubygems }}
|
64
|
+
bundler: ${{ matrix.bundler }}
|
65
|
+
bundler-cache: false
|
66
|
+
|
67
|
+
# Raw `bundle` will use the BUNDLE_GEMFILE set to matrix.gemfile (i.e. Appraisal.root)
|
68
|
+
# We need to do this first to get appraisal installed.
|
69
|
+
# NOTE: This does not use the main Gemfile at all.
|
70
|
+
- name: Install Root Appraisal
|
71
|
+
run: bundle
|
72
|
+
- name: Appraisal for ${{ matrix.appraisal }}
|
73
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle
|
74
|
+
- name: Tests for ${{ matrix.ruby }} via ${{ matrix.exec_cmd }}
|
75
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle exec ${{ matrix.exec_cmd }}
|
@@ -0,0 +1,67 @@
|
|
1
|
+
name: MRI 3.0 (EOL)
|
2
|
+
|
3
|
+
env:
|
4
|
+
K_SOUP_COV_DO: false
|
5
|
+
|
6
|
+
on:
|
7
|
+
push:
|
8
|
+
branches:
|
9
|
+
- 'main'
|
10
|
+
tags:
|
11
|
+
- '!*' # Do not execute on tags
|
12
|
+
pull_request:
|
13
|
+
branches:
|
14
|
+
- '*'
|
15
|
+
# Allow manually triggering the workflow.
|
16
|
+
workflow_dispatch:
|
17
|
+
|
18
|
+
permissions:
|
19
|
+
contents: read
|
20
|
+
|
21
|
+
# Cancels all previous workflow runs for the same branch that have not yet completed.
|
22
|
+
concurrency:
|
23
|
+
# The concurrency group contains the workflow name and the branch name.
|
24
|
+
group: "${{ github.workflow }}-${{ github.ref }}"
|
25
|
+
cancel-in-progress: true
|
26
|
+
|
27
|
+
jobs:
|
28
|
+
test:
|
29
|
+
name: Specs ${{ matrix.ruby }} ${{ matrix.appraisal }}${{ matrix.name_extra || '' }}
|
30
|
+
if: "!contains(github.event.commits[0].message, '[ci skip]') && !contains(github.event.commits[0].message, '[skip ci]')"
|
31
|
+
runs-on: ubuntu-22.04
|
32
|
+
continue-on-error: ${{ matrix.experimental || endsWith(matrix.ruby, 'head') }}
|
33
|
+
env: # $BUNDLE_GEMFILE must be set at job level, so it is set for all steps
|
34
|
+
BUNDLE_GEMFILE: ${{ github.workspace }}/${{ matrix.gemfile }}.gemfile
|
35
|
+
strategy:
|
36
|
+
fail-fast: false
|
37
|
+
matrix:
|
38
|
+
include:
|
39
|
+
# Ruby 3.0
|
40
|
+
- ruby: "ruby-3.0"
|
41
|
+
appraisal: "ruby-3-0"
|
42
|
+
exec_cmd: "rake test"
|
43
|
+
gemfile: "Appraisal.root"
|
44
|
+
rubygems: '3.5.23'
|
45
|
+
bundler: '2.5.23'
|
46
|
+
|
47
|
+
steps:
|
48
|
+
- name: Checkout
|
49
|
+
uses: actions/checkout@v5
|
50
|
+
|
51
|
+
- name: Setup Ruby & RubyGems
|
52
|
+
uses: ruby/setup-ruby@v1
|
53
|
+
with:
|
54
|
+
ruby-version: ${{ matrix.ruby }}
|
55
|
+
rubygems: ${{ matrix.rubygems }}
|
56
|
+
bundler: ${{ matrix.bundler }}
|
57
|
+
bundler-cache: false
|
58
|
+
|
59
|
+
# Raw `bundle` will use the BUNDLE_GEMFILE set to matrix.gemfile (i.e. Appraisal.root)
|
60
|
+
# We need to do this first to get appraisal installed.
|
61
|
+
# NOTE: This does not use the main Gemfile at all.
|
62
|
+
- name: Install Root Appraisal
|
63
|
+
run: bundle
|
64
|
+
- name: Appraisal for ${{ matrix.appraisal }}
|
65
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle
|
66
|
+
- name: Tests for ${{ matrix.ruby }} via ${{ matrix.exec_cmd }}
|
67
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle exec ${{ matrix.exec_cmd }}
|
@@ -0,0 +1,64 @@
|
|
1
|
+
name: Style
|
2
|
+
|
3
|
+
on:
|
4
|
+
push:
|
5
|
+
branches:
|
6
|
+
- 'main'
|
7
|
+
tags:
|
8
|
+
- '!*' # Do not execute on tags
|
9
|
+
pull_request:
|
10
|
+
branches:
|
11
|
+
- '*'
|
12
|
+
# Allow manually triggering the workflow.
|
13
|
+
workflow_dispatch:
|
14
|
+
|
15
|
+
permissions:
|
16
|
+
contents: read
|
17
|
+
|
18
|
+
# Cancels all previous workflow runs for the same branch that have not yet completed.
|
19
|
+
concurrency:
|
20
|
+
# The concurrency group contains the workflow name and the branch name.
|
21
|
+
group: "${{ github.workflow }}-${{ github.ref }}"
|
22
|
+
cancel-in-progress: true
|
23
|
+
|
24
|
+
jobs:
|
25
|
+
rubocop:
|
26
|
+
name: Style on ${{ matrix.ruby }}@current
|
27
|
+
if: "!contains(github.event.commits[0].message, '[ci skip]') && !contains(github.event.commits[0].message, '[skip ci]')"
|
28
|
+
runs-on: ubuntu-latest
|
29
|
+
continue-on-error: ${{ matrix.experimental || endsWith(matrix.ruby, 'head') }}
|
30
|
+
env: # $BUNDLE_GEMFILE must be set at job level, so it is set for all steps
|
31
|
+
BUNDLE_GEMFILE: ${{ github.workspace }}/${{ matrix.gemfile }}.gemfile
|
32
|
+
strategy:
|
33
|
+
fail-fast: false
|
34
|
+
matrix:
|
35
|
+
include:
|
36
|
+
# Style
|
37
|
+
- ruby: "ruby"
|
38
|
+
appraisal: "style"
|
39
|
+
exec_cmd: "rake rubocop_gradual:check"
|
40
|
+
gemfile: "Appraisal.root"
|
41
|
+
rubygems: latest
|
42
|
+
bundler: latest
|
43
|
+
|
44
|
+
steps:
|
45
|
+
- name: Checkout
|
46
|
+
uses: actions/checkout@v5
|
47
|
+
|
48
|
+
- name: Setup Ruby & RubyGems
|
49
|
+
uses: ruby/setup-ruby@v1
|
50
|
+
with:
|
51
|
+
ruby-version: ${{ matrix.ruby }}
|
52
|
+
rubygems: ${{ matrix.rubygems }}
|
53
|
+
bundler: ${{ matrix.bundler }}
|
54
|
+
bundler-cache: false
|
55
|
+
|
56
|
+
# Raw `bundle` will use the BUNDLE_GEMFILE set to matrix.gemfile (i.e. Appraisal.root)
|
57
|
+
# We need to do this first to get appraisal installed.
|
58
|
+
# NOTE: This does not use the main Gemfile at all.
|
59
|
+
- name: Install Root Appraisal
|
60
|
+
run: bundle
|
61
|
+
- name: Appraisal for ${{ matrix.appraisal }}
|
62
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle
|
63
|
+
- name: Run ${{ matrix.appraisal }} checks via ${{ matrix.exec_cmd }}
|
64
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle exec ${{ matrix.exec_cmd }}
|
@@ -0,0 +1,82 @@
|
|
1
|
+
name: MRI Non-EOL
|
2
|
+
|
3
|
+
env:
|
4
|
+
K_SOUP_COV_DO: false
|
5
|
+
|
6
|
+
on:
|
7
|
+
push:
|
8
|
+
branches:
|
9
|
+
- 'main'
|
10
|
+
tags:
|
11
|
+
- '!*' # Do not execute on tags
|
12
|
+
pull_request:
|
13
|
+
branches:
|
14
|
+
- '*'
|
15
|
+
# Allow manually triggering the workflow.
|
16
|
+
workflow_dispatch:
|
17
|
+
|
18
|
+
permissions:
|
19
|
+
contents: read
|
20
|
+
|
21
|
+
# Cancels all previous workflow runs for the same branch that have not yet completed.
|
22
|
+
concurrency:
|
23
|
+
# The concurrency group contains the workflow name and the branch name.
|
24
|
+
group: "${{ github.workflow }}-${{ github.ref }}"
|
25
|
+
cancel-in-progress: true
|
26
|
+
|
27
|
+
jobs:
|
28
|
+
test:
|
29
|
+
name: Specs ${{ matrix.ruby }} ${{ matrix.appraisal }}${{ matrix.name_extra || '' }}
|
30
|
+
if: "!contains(github.event.commits[0].message, '[ci skip]') && !contains(github.event.commits[0].message, '[skip ci]')"
|
31
|
+
runs-on: ubuntu-latest
|
32
|
+
continue-on-error: ${{ matrix.experimental || endsWith(matrix.ruby, 'head') }}
|
33
|
+
env: # $BUNDLE_GEMFILE must be set at job level, so it is set for all steps
|
34
|
+
BUNDLE_GEMFILE: ${{ github.workspace }}/${{ matrix.gemfile }}.gemfile
|
35
|
+
strategy:
|
36
|
+
matrix:
|
37
|
+
include:
|
38
|
+
# Ruby 3.1
|
39
|
+
- ruby: "ruby-3.1"
|
40
|
+
appraisal: "ruby-3-1"
|
41
|
+
exec_cmd: "rake test"
|
42
|
+
gemfile: "Appraisal.root"
|
43
|
+
rubygems: latest
|
44
|
+
bundler: latest
|
45
|
+
|
46
|
+
# Ruby 3.2
|
47
|
+
- ruby: "ruby-3.2"
|
48
|
+
appraisal: "ruby-3-2"
|
49
|
+
exec_cmd: "rake test"
|
50
|
+
gemfile: "Appraisal.root"
|
51
|
+
rubygems: latest
|
52
|
+
bundler: latest
|
53
|
+
|
54
|
+
# Ruby 3.3
|
55
|
+
- ruby: "ruby-3.3"
|
56
|
+
appraisal: "ruby-3-3"
|
57
|
+
exec_cmd: "rake test"
|
58
|
+
gemfile: "Appraisal.root"
|
59
|
+
rubygems: latest
|
60
|
+
bundler: latest
|
61
|
+
|
62
|
+
steps:
|
63
|
+
- name: Checkout
|
64
|
+
uses: actions/checkout@v5
|
65
|
+
|
66
|
+
- name: Setup Ruby & RubyGems
|
67
|
+
uses: ruby/setup-ruby@v1
|
68
|
+
with:
|
69
|
+
ruby-version: ${{ matrix.ruby }}
|
70
|
+
rubygems: ${{ matrix.rubygems }}
|
71
|
+
bundler: ${{ matrix.bundler }}
|
72
|
+
bundler-cache: false
|
73
|
+
|
74
|
+
# Raw `bundle` will use the BUNDLE_GEMFILE set to matrix.gemfile (i.e. Appraisal.root)
|
75
|
+
# We need to do this first to get appraisal installed.
|
76
|
+
# NOTE: This does not use the main Gemfile at all.
|
77
|
+
- name: Install Root Appraisal
|
78
|
+
run: bundle
|
79
|
+
- name: Appraisal for ${{ matrix.ruby }} ${{ matrix.appraisal }}
|
80
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle
|
81
|
+
- name: Tests for ${{ matrix.ruby }} ${{ matrix.appraisal }} via ${{ matrix.exec_cmd }}
|
82
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle exec ${{ matrix.exec_cmd }}
|
@@ -0,0 +1,75 @@
|
|
1
|
+
name: Truffle
|
2
|
+
|
3
|
+
env:
|
4
|
+
K_SOUP_COV_DO: false
|
5
|
+
|
6
|
+
on:
|
7
|
+
push:
|
8
|
+
branches:
|
9
|
+
- 'main'
|
10
|
+
tags:
|
11
|
+
- '!*' # Do not execute on tags
|
12
|
+
pull_request:
|
13
|
+
branches:
|
14
|
+
- '*'
|
15
|
+
# Allow manually triggering the workflow.
|
16
|
+
workflow_dispatch:
|
17
|
+
|
18
|
+
permissions:
|
19
|
+
contents: read
|
20
|
+
|
21
|
+
# Cancels all previous workflow runs for the same branch that have not yet completed.
|
22
|
+
concurrency:
|
23
|
+
# The concurrency group contains the workflow name and the branch name.
|
24
|
+
group: "${{ github.workflow }}-${{ github.ref }}"
|
25
|
+
cancel-in-progress: true
|
26
|
+
|
27
|
+
jobs:
|
28
|
+
test:
|
29
|
+
name: Specs ${{ matrix.ruby }} ${{ matrix.appraisal }}${{ matrix.name_extra || '' }}
|
30
|
+
if: "!contains(github.event.commits[0].message, '[ci skip]') && !contains(github.event.commits[0].message, '[skip ci]')"
|
31
|
+
runs-on: ubuntu-22.04
|
32
|
+
continue-on-error: ${{ matrix.experimental || endsWith(matrix.ruby, 'head') }}
|
33
|
+
env: # $BUNDLE_GEMFILE must be set at job level, so it is set for all steps
|
34
|
+
BUNDLE_GEMFILE: ${{ github.workspace }}/${{ matrix.gemfile }}.gemfile
|
35
|
+
strategy:
|
36
|
+
matrix:
|
37
|
+
include:
|
38
|
+
# NOTE: truffleruby does not support upgrading rubygems.
|
39
|
+
# truffleruby-23.0 (targets Ruby 3.1 compatibility)
|
40
|
+
- ruby: "truffleruby-23.0"
|
41
|
+
appraisal: "ruby-3-1"
|
42
|
+
exec_cmd: "rake test"
|
43
|
+
gemfile: "Appraisal.root"
|
44
|
+
rubygems: default
|
45
|
+
bundler: default
|
46
|
+
|
47
|
+
# truffleruby-23.1 (targets Ruby 3.2 compatibility)
|
48
|
+
- ruby: "truffleruby-23.1"
|
49
|
+
appraisal: "ruby-3-2"
|
50
|
+
exec_cmd: "rake test"
|
51
|
+
gemfile: "Appraisal.root"
|
52
|
+
rubygems: default
|
53
|
+
bundler: default
|
54
|
+
|
55
|
+
steps:
|
56
|
+
- name: Checkout
|
57
|
+
uses: actions/checkout@v5
|
58
|
+
|
59
|
+
- name: Setup Ruby & RubyGems
|
60
|
+
uses: ruby/setup-ruby@v1
|
61
|
+
with:
|
62
|
+
ruby-version: ${{ matrix.ruby }}
|
63
|
+
rubygems: ${{ matrix.rubygems }}
|
64
|
+
bundler: ${{ matrix.bundler }}
|
65
|
+
bundler-cache: false
|
66
|
+
|
67
|
+
# Raw `bundle` will use the BUNDLE_GEMFILE set to matrix.gemfile (i.e. Appraisal.root)
|
68
|
+
# We need to do this first to get appraisal installed.
|
69
|
+
# NOTE: This does not use the main Gemfile at all.
|
70
|
+
- name: Install Root Appraisal
|
71
|
+
run: bundle
|
72
|
+
- name: Appraisal for ${{ matrix.appraisal }}
|
73
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle
|
74
|
+
- name: Tests for ${{ matrix.ruby }} via ${{ matrix.exec_cmd }}
|
75
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle exec ${{ matrix.exec_cmd }}
|
@@ -0,0 +1,75 @@
|
|
1
|
+
name: MRI 2.6 & 2.7 (EOL)
|
2
|
+
|
3
|
+
env:
|
4
|
+
K_SOUP_COV_DO: false
|
5
|
+
|
6
|
+
on:
|
7
|
+
push:
|
8
|
+
branches:
|
9
|
+
- 'main'
|
10
|
+
tags:
|
11
|
+
- '!*' # Do not execute on tags
|
12
|
+
pull_request:
|
13
|
+
branches:
|
14
|
+
- '*'
|
15
|
+
# Allow manually triggering the workflow.
|
16
|
+
workflow_dispatch:
|
17
|
+
|
18
|
+
permissions:
|
19
|
+
contents: read
|
20
|
+
|
21
|
+
# Cancels all previous workflow runs for the same branch that have not yet completed.
|
22
|
+
concurrency:
|
23
|
+
# The concurrency group contains the workflow name and the branch name.
|
24
|
+
group: "${{ github.workflow }}-${{ github.ref }}"
|
25
|
+
cancel-in-progress: true
|
26
|
+
|
27
|
+
jobs:
|
28
|
+
test:
|
29
|
+
name: Specs ${{ matrix.ruby }} ${{ matrix.appraisal }}${{ matrix.name_extra || '' }}
|
30
|
+
if: "!contains(github.event.commits[0].message, '[ci skip]') && !contains(github.event.commits[0].message, '[skip ci]')"
|
31
|
+
runs-on: ubuntu-22.04
|
32
|
+
continue-on-error: ${{ matrix.experimental || endsWith(matrix.ruby, 'head') }}
|
33
|
+
env: # $BUNDLE_GEMFILE must be set at job level, so it is set for all steps
|
34
|
+
BUNDLE_GEMFILE: ${{ github.workspace }}/${{ matrix.gemfile }}.gemfile
|
35
|
+
strategy:
|
36
|
+
fail-fast: false
|
37
|
+
matrix:
|
38
|
+
include:
|
39
|
+
# Ruby 2.6
|
40
|
+
- ruby: "ruby-2.6"
|
41
|
+
appraisal: "ruby-2-6"
|
42
|
+
exec_cmd: "rake test"
|
43
|
+
gemfile: "Appraisal.root"
|
44
|
+
rubygems: '3.4.22'
|
45
|
+
bundler: '2.4.22'
|
46
|
+
|
47
|
+
# Ruby 2.7
|
48
|
+
- ruby: "ruby-2.7"
|
49
|
+
appraisal: "ruby-2-7"
|
50
|
+
exec_cmd: "rake test"
|
51
|
+
gemfile: "Appraisal.root"
|
52
|
+
rubygems: '3.4.22'
|
53
|
+
bundler: '2.4.22'
|
54
|
+
|
55
|
+
steps:
|
56
|
+
- name: Checkout
|
57
|
+
uses: actions/checkout@v5
|
58
|
+
|
59
|
+
- name: Setup Ruby & RubyGems
|
60
|
+
uses: ruby/setup-ruby@v1
|
61
|
+
with:
|
62
|
+
ruby-version: ${{ matrix.ruby }}
|
63
|
+
rubygems: ${{ matrix.rubygems }}
|
64
|
+
bundler: ${{ matrix.bundler }}
|
65
|
+
bundler-cache: false
|
66
|
+
|
67
|
+
# Raw `bundle` will use the BUNDLE_GEMFILE set to matrix.gemfile (i.e. Appraisal.root)
|
68
|
+
# We need to do this first to get appraisal installed.
|
69
|
+
# NOTE: This does not use the main Gemfile at all.
|
70
|
+
- name: Install Root Appraisal
|
71
|
+
run: bundle
|
72
|
+
- name: Appraisal for ${{ matrix.appraisal }}
|
73
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle
|
74
|
+
- name: Tests for ${{ matrix.ruby }} via ${{ matrix.exec_cmd }}
|
75
|
+
run: bundle exec appraisal ${{ matrix.appraisal }} bundle exec ${{ matrix.exec_cmd }}
|
data/.gitignore
ADDED
@@ -0,0 +1,45 @@
|
|
1
|
+
# Build Artifacts
|
2
|
+
/pkg/
|
3
|
+
/tmp/
|
4
|
+
*.gem
|
5
|
+
|
6
|
+
# Bundler
|
7
|
+
/.bundle/
|
8
|
+
/gemfiles/*.lock
|
9
|
+
/gemfiles/.bundle/
|
10
|
+
/gemfiles/.bundle/config
|
11
|
+
/gemfiles/vendor/
|
12
|
+
Appraisal.*.gemfile.lock
|
13
|
+
|
14
|
+
# Specs
|
15
|
+
.rspec_status
|
16
|
+
/coverage/
|
17
|
+
/spec/reports/
|
18
|
+
/results/
|
19
|
+
|
20
|
+
# Documentation
|
21
|
+
/.yardoc/
|
22
|
+
/_yardoc/
|
23
|
+
/rdoc/
|
24
|
+
/doc/
|
25
|
+
|
26
|
+
# Ruby Version Managers (RVM, rbenv, etc)
|
27
|
+
# Ignored because we currently use .tool-versions
|
28
|
+
.rvmrc
|
29
|
+
.ruby-version
|
30
|
+
.ruby-gemset
|
31
|
+
|
32
|
+
# Benchmarking
|
33
|
+
/measurement/
|
34
|
+
|
35
|
+
# Debugger detritus
|
36
|
+
.byebug_history
|
37
|
+
|
38
|
+
# direnv - brew install direnv
|
39
|
+
.env.local
|
40
|
+
|
41
|
+
# OS Detritus
|
42
|
+
.DS_Store
|
43
|
+
|
44
|
+
# Editors
|
45
|
+
*~
|
data/.gitlab-ci.yml
ADDED
@@ -0,0 +1,44 @@
|
|
1
|
+
default:
|
2
|
+
image: ruby
|
3
|
+
|
4
|
+
variables:
|
5
|
+
BUNDLE_INSTALL_FLAGS: "--quiet --jobs=$(nproc) --retry=3"
|
6
|
+
BUNDLE_FROZEN: "false" # No lockfile!
|
7
|
+
BUNDLE_GEMFILE: gemfiles/current.gemfile
|
8
|
+
K_SOUP_COV_DEBUG: true
|
9
|
+
K_SOUP_COV_DO: true
|
10
|
+
K_SOUP_COV_HARD: true
|
11
|
+
K_SOUP_COV_MIN_BRANCH: 100
|
12
|
+
K_SOUP_COV_MIN_LINE: 100
|
13
|
+
K_SOUP_COV_VERBOSE: true
|
14
|
+
K_SOUP_COV_FORMATTERS: "html,xml,rcov,lcov,json,tty"
|
15
|
+
K_SOUP_COV_MULTI_FORMATTERS: true
|
16
|
+
K_SOUP_COV_COMMAND_NAME: "RSpec Coverage"
|
17
|
+
|
18
|
+
workflow:
|
19
|
+
rules:
|
20
|
+
# For merge requests, create a pipeline.
|
21
|
+
- if: '$CI_MERGE_REQUEST_IID'
|
22
|
+
# For the ` main ` branch, create a pipeline (this includes on schedules, pushes, merges, etc.).
|
23
|
+
- if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH'
|
24
|
+
# For tags, create a pipeline.
|
25
|
+
- if: '$CI_COMMIT_TAG'
|
26
|
+
|
27
|
+
.current_ruby_template: ¤t_ruby_template
|
28
|
+
image: ruby:${RUBY_VERSION}
|
29
|
+
stage: test
|
30
|
+
script:
|
31
|
+
- gem update --system > /dev/null 2>&1
|
32
|
+
- bundle config --local path vendor
|
33
|
+
- bundle
|
34
|
+
- bundle exec rake
|
35
|
+
cache:
|
36
|
+
key: ${CI_JOB_IMAGE}
|
37
|
+
paths:
|
38
|
+
- vendor/ruby
|
39
|
+
|
40
|
+
current-ruby:
|
41
|
+
<<: *current_ruby_template
|
42
|
+
parallel:
|
43
|
+
matrix:
|
44
|
+
- RUBY_VERSION: ["3.2", "3.3", "3.4"]
|
data/.idea/.gitignore
ADDED
data/.idea/GitLink.xml
ADDED
data/.idea/misc.xml
ADDED
data/.idea/modules.xml
ADDED
@@ -0,0 +1,8 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<project version="4">
|
3
|
+
<component name="ProjectModuleManager">
|
4
|
+
<modules>
|
5
|
+
<module fileurl="file://$PROJECT_DIR$/.idea/timecop-rspec.iml" filepath="$PROJECT_DIR$/.idea/timecop-rspec.iml" />
|
6
|
+
</modules>
|
7
|
+
</component>
|
8
|
+
</project>
|