mutant 0.12.1 → 0.12.2

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: 0e1cf4d744b27691dff3986c4af5dddd278e6eadcc348a9cd0d4b5e16fa22514
4
- data.tar.gz: 77913d65e176d5150b17ca03ec5b05398dee759dfea2ad89dd438eeaf72e34f8
3
+ metadata.gz: b917d54d9bc5f8bd16f530001c6cf983ad0a0970d3e837f0736b31efb81e5c8d
4
+ data.tar.gz: 499669d7e30d80698a154b27f37f52893b504b30bb70b6edd473f118c9d49c74
5
5
  SHA512:
6
- metadata.gz: 6d8ec46587bb0b896b0322b57766a6e8bbe51ea00777e538cacd5f6a329d1a3e47c513ccaec720050a3a37049e65dc9be627f25006cc0404cb294fb0ba0a55d6
7
- data.tar.gz: d0f457130db225049774066ad235cc00db9f3c1ca75c9994c618798a94567867fb21c84059c0a3878ae88736ad9b4d325b2e75f552bef583cd3cb846e48fc0c9
6
+ metadata.gz: caea8e933129291143d45128074ffeb821ad1acf2f8b9742351b5512c867f8909512c8f6716dca423c49d912ecfae631caea7543d6862f9c5193694b393ad624
7
+ data.tar.gz: 336f5ed118fa5f63cf5b30f080ab3218fa488937a5f75bf8b486ed77b8869fd1c69e57414f4f8453d8e29c00c016b483e9cda02d91ccd4b1ec166494c0aa9bee
data/lib/mutant/config.rb CHANGED
@@ -111,14 +111,13 @@ module Mutant
111
111
  #
112
112
  # @return [Either<String,Config>]
113
113
  def self.load_config_file(reporter:, world:)
114
- files = CANDIDATES
115
- .map(&world.pathname.public_method(:new))
116
- .select(&:readable?)
114
+ files = CANDIDATES.map(&world.pathname.public_method(:new)).select(&:readable?)
117
115
 
118
- if files.one?
119
- load_contents(reporter: reporter, path: files.first).fmap(&DEFAULT.public_method(:with))
120
- elsif files.empty?
116
+ case files
117
+ in []
121
118
  Either::Right.new(DEFAULT)
119
+ in [file]
120
+ load_contents(reporter: reporter, path: file).fmap(&DEFAULT.public_method(:with))
122
121
  else
123
122
  Either::Left.new(MORE_THAN_ONE_CONFIG_FILE % files.join(', '))
124
123
  end
@@ -15,12 +15,11 @@ module Mutant
15
15
  # @return [nil]
16
16
  # otherwise
17
17
  def call(input)
18
- expressions = expressions(input)
19
- case expressions.length
20
- when 0
18
+ case expressions(input)
19
+ in []
21
20
  Either::Left.new("Expression: #{input.inspect} is invalid")
22
- when 1
23
- Either::Right.new(expressions.first)
21
+ in [expression]
22
+ Either::Right.new(expression)
24
23
  else
25
24
  Either::Left.new("Expression: #{input.inspect} is ambiguous")
26
25
  end
@@ -13,7 +13,6 @@ module Mutant
13
13
 
14
14
  def dispatch
15
15
  emit_singletons
16
- emit(N_EMPTY_SUPER)
17
16
  children.each_index do |index|
18
17
  mutate_child(index)
19
18
  delete_child(index)
@@ -2,5 +2,5 @@
2
2
 
3
3
  module Mutant
4
4
  # Current mutant version
5
- VERSION = '0.12.1'
5
+ VERSION = '0.12.2'
6
6
  end # Mutant
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mutant
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.12.1
4
+ version: 0.12.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Markus Schirp
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-05-12 00:00:00.000000000 Z
11
+ date: 2024-06-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: diff-lcs
@@ -346,6 +346,7 @@ licenses:
346
346
  - Nonstandard
347
347
  metadata:
348
348
  rubygems_mfa_required: 'true'
349
+ source_code_uri: https://github.com/mbj/mutant
349
350
  post_install_message:
350
351
  rdoc_options: []
351
352
  require_paths:
@@ -361,7 +362,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
361
362
  - !ruby/object:Gem::Version
362
363
  version: '0'
363
364
  requirements: []
364
- rubygems_version: 3.5.3
365
+ rubygems_version: 3.5.9
365
366
  signing_key:
366
367
  specification_version: 4
367
368
  summary: ''