code_analyzer 0.5.3 → 0.5.4
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/lib/code_analyzer/sexp.rb +2 -0
- data/lib/code_analyzer/version.rb +1 -1
- data/spec/code_analyzer/sexp_spec.rb +8 -0
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6649593166b051c563e05a6a3a2130a1d369a6b828e5477a2f3d392f15ea691f
|
4
|
+
data.tar.gz: e78c03b663ad0951deee38f8202eaa73613a88690ccb5e43b07d81b3ca971f57
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 395be11e15e5a7ff181c381c1790b4b826c849d1ae4e1aadb1f002a9825f2976e3c696c4b710593c6b57d7e1d6cc742364ba24b2c9a4b5859e01ba86a1fd8a5b
|
7
|
+
data.tar.gz: 5aedb0a332cab72f10ad39dff8cc395133f8fb5170ae82ae7d01b8af9073a16d9d6c994af4046ab3f99ffd4edfbb0075fad5c0510b6bcbf83db6f0add433c03a
|
data/lib/code_analyzer/sexp.rb
CHANGED
@@ -662,6 +662,14 @@ describe Sexp do
|
|
662
662
|
)
|
663
663
|
expect(node.value).to eq 'Richard'
|
664
664
|
end
|
665
|
+
|
666
|
+
it 'should get array value for assoc_new' do
|
667
|
+
node =
|
668
|
+
parse_content("add_user :user, name: %w[Richard Huang]").grep_node(
|
669
|
+
sexp_type: :assoc_new
|
670
|
+
)
|
671
|
+
expect(node.value.array_values.map(&:to_s)).to eq ['Richard', 'Huang']
|
672
|
+
end
|
665
673
|
end
|
666
674
|
|
667
675
|
describe 'array_size' do
|