flog 4.5.0 → 4.6.0

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
  SHA1:
3
- metadata.gz: bbfedb8bc3e677559e32945d5b16595988bc1f34
4
- data.tar.gz: 19b4cfb958495d27cc6af83f2702c233863db0e9
3
+ metadata.gz: 7d1c4c8c172083faeb6757dc0a21dd88a2c1cef5
4
+ data.tar.gz: a10a474b9cb3b31845f23b77ac3a40cbc9c86c85
5
5
  SHA512:
6
- metadata.gz: c389b30f3fa2612ebdd0635455e9154458781aa82540dcd45376496aae5825a19994bf08aa7d28ab858c042c683c6ded6be87fc436c49ffd1eac8f26eaa6944c
7
- data.tar.gz: a987ad2bb5949884237e3b69f2a6d120b5f2478632b0aee996917d07f410ba04190b02d7544d84de93c1058c3da6836669d05568f6c5813ddb12678d6f818398
6
+ metadata.gz: 6f2a58932ddb091ef2ad64027fd78c78b18978783d472075cd2f1f2d88e6d06e1924a6cdb8a04a1f7e048b8e3a18c1ec2d32cdab2adb382766b00c5cd1f10e94
7
+ data.tar.gz: 1024eaae31c28f157176b7bfc1c4c9c6674b0692fe8e3ad4791f7c604fc48d7eec36cbccd14385cc261427974a81aa2e52799e5ba2f5d4b04fdd5bb79f546fe6
@@ -1,3 +1 @@
1
- ���R��ԅaR{Nh�+�RL�aQ�M��RmHx�Kl�s��B�H���s�A'�a�q��7۞�K�U$rD�u�/��% Ƙ����{����MU��W�0��k��S=�A�P������ls%�jY�V�u4�%��{)Y�+h�
2
- ��,�Ye}H�uZ�&�z�k(ZxL
3
- �X5�KV���g\J��(fo�FzǠUM�r%&+��h)
1
+ 9�����>./J��ۋ��5]v����
data.tar.gz.sig CHANGED
Binary file
@@ -1,3 +1,10 @@
1
+ === 4.6.0 / 2017-02-01
2
+
3
+ * 2 minor enhancements:
4
+
5
+ * Bumped dependency on sexp_processor to 4.8 and up.
6
+ * Include new Sexp#line_max info for in_method so DSLs can record line span.
7
+
1
8
  === 4.5.0 / 2017-01-19
2
9
 
3
10
  * 3 minor enhancements:
data/Rakefile CHANGED
@@ -22,7 +22,7 @@ Hoe.spec 'flog' do
22
22
 
23
23
  license "MIT"
24
24
 
25
- dependency "sexp_processor", "~> 4.4"
25
+ dependency "sexp_processor", "~> 4.8"
26
26
  dependency "ruby_parser", ["~> 3.1", "> 3.1.0"]
27
27
  dependency "path_expander", "~> 1.0"
28
28
  end
@@ -11,7 +11,7 @@ class File
11
11
  end
12
12
 
13
13
  class Flog < MethodBasedSexpProcessor
14
- VERSION = "4.5.0" # :nodoc:
14
+ VERSION = "4.6.0" # :nodoc:
15
15
 
16
16
  ##
17
17
  # Cut off point where the report should stop unless --all given.
@@ -233,7 +233,6 @@ class Flog < MethodBasedSexpProcessor
233
233
  def initialize option = {}
234
234
  super()
235
235
  @option = option
236
- @method_locations = {}
237
236
  @mass = {}
238
237
  @parser = nil
239
238
  @threshold = option[:threshold] || DEFAULT_THRESHOLD
@@ -468,7 +467,7 @@ class Flog < MethodBasedSexpProcessor
468
467
  if t == :call and r == nil and submsg = dsl_name?(a) then
469
468
  m = "#{m}(#{submsg})" if m and [String, Symbol].include?(submsg.class)
470
469
  in_klass m do # :task/namespace
471
- in_method submsg, exp.file, exp.line do # :name
470
+ in_method submsg, exp.file, exp.line, exp.max_line do # :name
472
471
  process_until_empty exp
473
472
  end
474
473
  end
@@ -566,7 +566,7 @@ class TestFlog < FlogTest
566
566
  @flog.calculate_total_scores
567
567
  @flog.calculate
568
568
 
569
- assert_equal({ 'User#blah' => 'user.rb:3' }, @flog.method_locations)
569
+ assert_equal({ 'User#blah' => 'user.rb:3-4' }, @flog.method_locations)
570
570
  assert_equal({ "User#blah" => 2.2 }, @flog.totals)
571
571
  assert_in_epsilon(2.2, @flog.total_score)
572
572
  assert_in_epsilon(1.0, @flog.multiplier)
@@ -588,7 +588,7 @@ class TestFlog < FlogTest
588
588
  @flog.calculate_total_scores
589
589
  @flog.calculate
590
590
 
591
- assert_equal({ 'Coder#happy?' => 'coder.rb:3' }, @flog.method_locations)
591
+ assert_equal({ 'Coder#happy?' => 'coder.rb:3-4' }, @flog.method_locations)
592
592
  assert_equal({ "Coder#happy?" => 1.0 }, @flog.totals)
593
593
  assert_in_epsilon(1.0, @flog.total_score)
594
594
  assert_in_epsilon(1.0, @flog.multiplier)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: flog
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.5.0
4
+ version: 4.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan Davis
@@ -30,7 +30,7 @@ cert_chain:
30
30
  E4oJcnPkJAr0rw504JGtlZtONZQblwmRJOIdXzolaE3NRGUzGVOUSptZppAKiavY
31
31
  fO6tdKQc/5RfA8oQEkg8hrxA5PQSz4TOFJGLpFvIapEk6tMruQ0bHgkhr9auXg==
32
32
  -----END CERTIFICATE-----
33
- date: 2017-01-20 00:00:00.000000000 Z
33
+ date: 2017-02-01 00:00:00.000000000 Z
34
34
  dependencies:
35
35
  - !ruby/object:Gem::Dependency
36
36
  name: sexp_processor
@@ -38,14 +38,14 @@ dependencies:
38
38
  requirements:
39
39
  - - "~>"
40
40
  - !ruby/object:Gem::Version
41
- version: '4.4'
41
+ version: '4.8'
42
42
  type: :runtime
43
43
  prerelease: false
44
44
  version_requirements: !ruby/object:Gem::Requirement
45
45
  requirements:
46
46
  - - "~>"
47
47
  - !ruby/object:Gem::Version
48
- version: '4.4'
48
+ version: '4.8'
49
49
  - !ruby/object:Gem::Dependency
50
50
  name: ruby_parser
51
51
  requirement: !ruby/object:Gem::Requirement
metadata.gz.sig CHANGED
Binary file