fbe 0.0.85 → 0.0.86

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.
Files changed (69) hide show
  1. checksums.yaml +4 -4
  2. data/.0pdd.yml +1 -1
  3. data/.github/workflows/actionlint.yml +1 -1
  4. data/.github/workflows/codecov.yml +2 -2
  5. data/.github/workflows/copyrights.yml +1 -1
  6. data/.github/workflows/markdown-lint.yml +1 -1
  7. data/.github/workflows/pdd.yml +1 -1
  8. data/.github/workflows/rake.yml +1 -1
  9. data/.github/workflows/xcop.yml +1 -1
  10. data/.github/workflows/yamllint.yml +1 -1
  11. data/.gitignore +1 -1
  12. data/.rubocop.yml +6 -1
  13. data/.rultor.yml +1 -1
  14. data/.simplecov +1 -1
  15. data/.yamllint.yml +1 -1
  16. data/Gemfile +4 -3
  17. data/Gemfile.lock +46 -33
  18. data/LICENSE.txt +1 -1
  19. data/Rakefile +1 -1
  20. data/assets/bylaws/dud-was-punished.liquid +1 -1
  21. data/fbe.gemspec +2 -2
  22. data/lib/fbe/award.rb +28 -10
  23. data/lib/fbe/bylaws.rb +1 -1
  24. data/lib/fbe/conclude.rb +3 -3
  25. data/lib/fbe/copy.rb +1 -1
  26. data/lib/fbe/enter.rb +1 -1
  27. data/lib/fbe/fb.rb +1 -1
  28. data/lib/fbe/github_graph.rb +2 -2
  29. data/lib/fbe/if_absent.rb +2 -2
  30. data/lib/fbe/issue.rb +1 -1
  31. data/lib/fbe/iterate.rb +2 -2
  32. data/lib/fbe/just_one.rb +2 -2
  33. data/lib/fbe/middleware/formatter.rb +2 -2
  34. data/lib/fbe/middleware/quota.rb +2 -2
  35. data/lib/fbe/middleware.rb +2 -2
  36. data/lib/fbe/octo.rb +4 -4
  37. data/lib/fbe/overwrite.rb +2 -2
  38. data/lib/fbe/pmp.rb +1 -1
  39. data/lib/fbe/regularly.rb +1 -1
  40. data/lib/fbe/repeatedly.rb +1 -1
  41. data/lib/fbe/sec.rb +1 -1
  42. data/lib/fbe/unmask_repos.rb +1 -1
  43. data/lib/fbe/who.rb +1 -1
  44. data/lib/fbe.rb +3 -3
  45. data/rules/basic.fe +1 -1
  46. data/test/fbe/middleware/test_formatter.rb +10 -8
  47. data/test/fbe/middleware/test_quota.rb +1 -1
  48. data/test/fbe/test_award.rb +6 -6
  49. data/test/fbe/test_bylaws.rb +5 -5
  50. data/test/fbe/test_conclude.rb +2 -2
  51. data/test/fbe/test_copy.rb +3 -3
  52. data/test/fbe/test_enter.rb +2 -2
  53. data/test/fbe/test_fb.rb +7 -7
  54. data/test/fbe/test_github_graph.rb +17 -17
  55. data/test/fbe/test_if_absent.rb +6 -6
  56. data/test/fbe/test_issue.rb +2 -2
  57. data/test/fbe/test_iterate.rb +2 -2
  58. data/test/fbe/test_just_one.rb +3 -3
  59. data/test/fbe/test_octo.rb +10 -10
  60. data/test/fbe/test_overwrite.rb +3 -3
  61. data/test/fbe/test_pmp.rb +3 -3
  62. data/test/fbe/test_regularly.rb +2 -2
  63. data/test/fbe/test_repeatedly.rb +2 -2
  64. data/test/fbe/test_sec.rb +2 -2
  65. data/test/fbe/test_unmask_repos.rb +6 -6
  66. data/test/fbe/test_who.rb +2 -2
  67. data/test/test__helper.rb +1 -1
  68. data/test/test_fbe.rb +3 -3
  69. metadata +6 -6
@@ -2,7 +2,7 @@
2
2
 
3
3
  # MIT License
4
4
  #
5
- # Copyright (c) 2024 Zerocracy
5
+ # Copyright (c) 2024-2025 Zerocracy
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a copy
8
8
  # of this software and associated documentation files (the "Software"), to deal
@@ -31,16 +31,16 @@ require_relative '../../lib/fbe/octo'
31
31
 
32
32
  # Test.
33
33
  # Author:: Yegor Bugayenko (yegor256@gmail.com)
34
- # Copyright:: Copyright (c) 2024 Zerocracy
34
+ # Copyright:: Copyright (c) 2024-2025 Zerocracy
35
35
  # License:: MIT
36
36
  class TestOcto < Minitest::Test
37
37
  def test_simple_use
38
38
  global = {}
39
39
  options = Judges::Options.new({ 'testing' => true })
40
40
  o = Fbe.octo(loog: Loog::NULL, global:, options:)
41
- assert(!o.off_quota)
42
- assert(!o.pull_request('foo/foo', 42).nil?)
43
- assert(!o.commit_pulls('foo/foo', 'sha').nil?)
41
+ refute(o.off_quota)
42
+ refute_nil(o.pull_request('foo/foo', 42))
43
+ refute_nil(o.commit_pulls('foo/foo', 'sha'))
44
44
  end
45
45
 
46
46
  def test_post_comment
@@ -82,7 +82,7 @@ class TestOcto < Minitest::Test
82
82
  stub_request(:get, 'https://api.github.com/rate_limit')
83
83
  .to_return(status: 200, body: '{}', headers: { 'X-RateLimit-Remaining' => '1000' })
84
84
  o = Fbe.octo(loog: Loog::NULL, global: {}, options: Judges::Options.new)
85
- assert(!o.off_quota)
85
+ refute(o.off_quota)
86
86
  end
87
87
 
88
88
  def test_retrying
@@ -110,12 +110,12 @@ class TestOcto < Minitest::Test
110
110
  end
111
111
 
112
112
  def test_with_broken_token
113
- skip # it's a "live" test, run it manually if you need it
113
+ skip("it's a live test, run it manually if you need it")
114
114
  WebMock.enable_net_connect!
115
115
  global = {}
116
116
  options = Judges::Options.new({ 'github_token' => 'incorrect-value' })
117
117
  o = Fbe.octo(loog: Loog::NULL, global:, options:)
118
- assert_raises { o.repository('zerocracy/fbe') }
118
+ assert_raises(StandardError) { o.repository('zerocracy/fbe') }
119
119
  end
120
120
 
121
121
  def test_workflow_run_usage
@@ -125,7 +125,7 @@ class TestOcto < Minitest::Test
125
125
  end
126
126
 
127
127
  def test_commit_pulls
128
- skip # it's a "live" test, run it manually if you need it
128
+ skip("it's a live test, run it manually if you need it")
129
129
  WebMock.enable_net_connect!
130
130
  o = Fbe.octo(loog: Loog::NULL, global: {}, options: Judges::Options.new)
131
131
  assert_equal(1, o.commit_pulls('zerocracy/fbe', '0b7d0699bd744b62c0731064c2adaad0c58e1416').size)
@@ -165,7 +165,7 @@ class TestOcto < Minitest::Test
165
165
  )
166
166
  .times(1)
167
167
  o.user(user)
168
- assert(!o.off_quota) if n > 100
168
+ refute(o.off_quota) if n > 100
169
169
  limit -= 1
170
170
  end
171
171
  assert_in_delta(pause, Time.now - start_time, 5)
@@ -2,7 +2,7 @@
2
2
 
3
3
  # MIT License
4
4
  #
5
- # Copyright (c) 2024 Zerocracy
5
+ # Copyright (c) 2024-2025 Zerocracy
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a copy
8
8
  # of this software and associated documentation files (the "Software"), to deal
@@ -29,7 +29,7 @@ require_relative '../../lib/fbe/overwrite'
29
29
 
30
30
  # Test.
31
31
  # Author:: Yegor Bugayenko (yegor256@gmail.com)
32
- # Copyright:: Copyright (c) 2024 Zerocracy
32
+ # Copyright:: Copyright (c) 2024-2025 Zerocracy
33
33
  # License:: MIT
34
34
  class TestOverwrite < Minitest::Test
35
35
  def test_simple_overwrite
@@ -76,7 +76,7 @@ class TestOverwrite < Minitest::Test
76
76
  def test_without_id
77
77
  fb = Factbase.new
78
78
  f = fb.insert
79
- assert_raises do
79
+ assert_raises(StandardError) do
80
80
  Fbe.overwrite(f, 'foo', 42, fb:)
81
81
  end
82
82
  end
data/test/fbe/test_pmp.rb CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  # MIT License
4
4
  #
5
- # Copyright (c) 2024 Zerocracy
5
+ # Copyright (c) 2024-2025 Zerocracy
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a copy
8
8
  # of this software and associated documentation files (the "Software"), to deal
@@ -31,7 +31,7 @@ require_relative '../../lib/fbe/pmp'
31
31
 
32
32
  # Test.
33
33
  # Author:: Yegor Bugayenko (yegor256@gmail.com)
34
- # Copyright:: Copyright (c) 2024 Zerocracy
34
+ # Copyright:: Copyright (c) 2024-2025 Zerocracy
35
35
  # License:: MIT
36
36
  class TestPmp < Minitest::Test
37
37
  def test_defaults
@@ -49,6 +49,6 @@ class TestPmp < Minitest::Test
49
49
  def test_fail_on_wrong_area
50
50
  $global = {}
51
51
  $loog = Loog::NULL
52
- assert_raises { Fbe.pmp(Factbase.new, loog: Loog::NULL).something }
52
+ assert_raises(StandardError) { Fbe.pmp(Factbase.new, loog: Loog::NULL).something }
53
53
  end
54
54
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  # MIT License
4
4
  #
5
- # Copyright (c) 2024 Zerocracy
5
+ # Copyright (c) 2024-2025 Zerocracy
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a copy
8
8
  # of this software and associated documentation files (the "Software"), to deal
@@ -30,7 +30,7 @@ require_relative '../../lib/fbe/regularly'
30
30
 
31
31
  # Test.
32
32
  # Author:: Yegor Bugayenko (yegor256@gmail.com)
33
- # Copyright:: Copyright (c) 2024 Zerocracy
33
+ # Copyright:: Copyright (c) 2024-2025 Zerocracy
34
34
  # License:: MIT
35
35
  class TestRegularly < Minitest::Test
36
36
  def test_simple
@@ -2,7 +2,7 @@
2
2
 
3
3
  # MIT License
4
4
  #
5
- # Copyright (c) 2024 Zerocracy
5
+ # Copyright (c) 2024-2025 Zerocracy
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a copy
8
8
  # of this software and associated documentation files (the "Software"), to deal
@@ -31,7 +31,7 @@ require_relative '../../lib/fbe/repeatedly'
31
31
 
32
32
  # Test.
33
33
  # Author:: Yegor Bugayenko (yegor256@gmail.com)
34
- # Copyright:: Copyright (c) 2024 Zerocracy
34
+ # Copyright:: Copyright (c) 2024-2025 Zerocracy
35
35
  # License:: MIT
36
36
  class TestRepeatedly < Minitest::Test
37
37
  def test_simple
data/test/fbe/test_sec.rb CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  # MIT License
4
4
  #
5
- # Copyright (c) 2024 Zerocracy
5
+ # Copyright (c) 2024-2025 Zerocracy
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a copy
8
8
  # of this software and associated documentation files (the "Software"), to deal
@@ -28,7 +28,7 @@ require_relative '../../lib/fbe/sec'
28
28
 
29
29
  # Test.
30
30
  # Author:: Yegor Bugayenko (yegor256@gmail.com)
31
- # Copyright:: Copyright (c) 2024 Zerocracy
31
+ # Copyright:: Copyright (c) 2024-2025 Zerocracy
32
32
  # License:: MIT
33
33
  class TestSec < Minitest::Test
34
34
  def test_simple
@@ -2,7 +2,7 @@
2
2
 
3
3
  # MIT License
4
4
  #
5
- # Copyright (c) 2024 Zerocracy
5
+ # Copyright (c) 2024-2025 Zerocracy
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a copy
8
8
  # of this software and associated documentation files (the "Software"), to deal
@@ -30,7 +30,7 @@ require_relative '../../lib/fbe/unmask_repos'
30
30
 
31
31
  # Test.
32
32
  # Author:: Yegor Bugayenko (yegor256@gmail.com)
33
- # Copyright:: Copyright (c) 2024 Zerocracy
33
+ # Copyright:: Copyright (c) 2024-2025 Zerocracy
34
34
  # License:: MIT
35
35
  class TestUnmaskRepos < Minitest::Test
36
36
  def test_simple_use
@@ -41,7 +41,7 @@ class TestUnmaskRepos < Minitest::Test
41
41
  }
42
42
  )
43
43
  list = Fbe.unmask_repos(options: opts, global: {}, loog: Loog::NULL)
44
- assert(list.size.positive?)
44
+ assert_predicate(list.size, :positive?)
45
45
  refute_includes(list, 'zerocracy/datum')
46
46
  end
47
47
 
@@ -53,9 +53,9 @@ class TestUnmaskRepos < Minitest::Test
53
53
  }
54
54
  )
55
55
  list = Fbe.unmask_repos(options: opts, global: {}, loog: Loog::NULL)
56
- assert(list.size.positive?)
57
- assert(list.include?('zerocracy/pages-action'))
58
- assert(!list.include?('zerocracy/judges-action'))
56
+ assert_predicate(list.size, :positive?)
57
+ assert_includes(list, 'zerocracy/pages-action')
58
+ refute_includes(list, 'zerocracy/judges-action')
59
59
  refute_includes(list, 'zerocracy/datum')
60
60
  end
61
61
  end
data/test/fbe/test_who.rb CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  # MIT License
4
4
  #
5
- # Copyright (c) 2024 Zerocracy
5
+ # Copyright (c) 2024-2025 Zerocracy
6
6
  #
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a copy
8
8
  # of this software and associated documentation files (the "Software"), to deal
@@ -29,7 +29,7 @@ require_relative '../../lib/fbe/who'
29
29
 
30
30
  # Test.
31
31
  # Author:: Yegor Bugayenko (yegor256@gmail.com)
32
- # Copyright:: Copyright (c) 2024 Zerocracy
32
+ # Copyright:: Copyright (c) 2024-2025 Zerocracy
33
33
  # License:: MIT
34
34
  class TestWho < Minitest::Test
35
35
  def test_simple
data/test/test__helper.rb CHANGED
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- # Copyright (c) 2024 Zerocracy
3
+ # Copyright (c) 2024-2025 Zerocracy
4
4
  #
5
5
  # Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  # of this software and associated documentation files (the 'Software'), to deal
data/test/test_fbe.rb CHANGED
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- # Copyright (c) 2024 Zerocracy
3
+ # Copyright (c) 2024-2025 Zerocracy
4
4
  #
5
5
  # Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  # of this software and associated documentation files (the 'Software'), to deal
@@ -26,10 +26,10 @@ require_relative '../lib/fbe'
26
26
 
27
27
  # Main module test.
28
28
  # Author:: Yegor Bugayenko (yegor256@gmail.com)
29
- # Copyright:: Copyright (c) 2024 Zerocracy
29
+ # Copyright:: Copyright (c) 2024-2025 Zerocracy
30
30
  # License:: MIT
31
31
  class TestFbe < Minitest::Test
32
32
  def test_simple
33
- assert(!Fbe::VERSION.nil?)
33
+ refute_nil(Fbe::VERSION)
34
34
  end
35
35
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fbe
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.85
4
+ version: 0.0.86
5
5
  platform: ruby
6
6
  authors:
7
7
  - Yegor Bugayenko
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-12-20 00:00:00.000000000 Z
11
+ date: 2025-01-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: backtrace
@@ -56,16 +56,16 @@ dependencies:
56
56
  name: factbase
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - "~>"
59
+ - - ">="
60
60
  - !ruby/object:Gem::Version
61
- version: '0'
61
+ version: 0.5.2
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - "~>"
66
+ - - ">="
67
67
  - !ruby/object:Gem::Version
68
- version: '0'
68
+ version: 0.5.2
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: faraday
71
71
  requirement: !ruby/object:Gem::Requirement