super_diff 0.1.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.
Files changed (70) hide show
  1. checksums.yaml +7 -0
  2. data/README.md +174 -0
  3. data/lib/super_diff/csi/color_helper.rb +52 -0
  4. data/lib/super_diff/csi/eight_bit_color.rb +131 -0
  5. data/lib/super_diff/csi/eight_bit_sequence.rb +27 -0
  6. data/lib/super_diff/csi/four_bit_color.rb +80 -0
  7. data/lib/super_diff/csi/four_bit_sequence.rb +24 -0
  8. data/lib/super_diff/csi/reset_sequence.rb +9 -0
  9. data/lib/super_diff/csi/sequence.rb +22 -0
  10. data/lib/super_diff/csi/twenty_four_bit_color.rb +41 -0
  11. data/lib/super_diff/csi/twenty_four_bit_sequence.rb +27 -0
  12. data/lib/super_diff/csi.rb +29 -0
  13. data/lib/super_diff/diff_formatter.rb +37 -0
  14. data/lib/super_diff/diff_formatters/array.rb +21 -0
  15. data/lib/super_diff/diff_formatters/base.rb +37 -0
  16. data/lib/super_diff/diff_formatters/collection.rb +107 -0
  17. data/lib/super_diff/diff_formatters/hash.rb +34 -0
  18. data/lib/super_diff/diff_formatters/multi_line_string.rb +31 -0
  19. data/lib/super_diff/diff_formatters/object.rb +27 -0
  20. data/lib/super_diff/diff_formatters.rb +5 -0
  21. data/lib/super_diff/differ.rb +48 -0
  22. data/lib/super_diff/differs/array.rb +24 -0
  23. data/lib/super_diff/differs/base.rb +42 -0
  24. data/lib/super_diff/differs/empty.rb +13 -0
  25. data/lib/super_diff/differs/hash.rb +24 -0
  26. data/lib/super_diff/differs/multi_line_string.rb +27 -0
  27. data/lib/super_diff/differs/object.rb +68 -0
  28. data/lib/super_diff/differs.rb +5 -0
  29. data/lib/super_diff/equality_matcher.rb +45 -0
  30. data/lib/super_diff/equality_matchers/array.rb +44 -0
  31. data/lib/super_diff/equality_matchers/base.rb +42 -0
  32. data/lib/super_diff/equality_matchers/hash.rb +44 -0
  33. data/lib/super_diff/equality_matchers/multi_line_string.rb +44 -0
  34. data/lib/super_diff/equality_matchers/object.rb +18 -0
  35. data/lib/super_diff/equality_matchers/single_line_string.rb +28 -0
  36. data/lib/super_diff/equality_matchers.rb +5 -0
  37. data/lib/super_diff/errors.rb +20 -0
  38. data/lib/super_diff/helpers.rb +96 -0
  39. data/lib/super_diff/operation_sequences/array.rb +14 -0
  40. data/lib/super_diff/operation_sequences/base.rb +11 -0
  41. data/lib/super_diff/operation_sequences/hash.rb +14 -0
  42. data/lib/super_diff/operation_sequences/object.rb +14 -0
  43. data/lib/super_diff/operational_sequencer.rb +43 -0
  44. data/lib/super_diff/operational_sequencers/array.rb +127 -0
  45. data/lib/super_diff/operational_sequencers/base.rb +97 -0
  46. data/lib/super_diff/operational_sequencers/hash.rb +82 -0
  47. data/lib/super_diff/operational_sequencers/multi_line_string.rb +85 -0
  48. data/lib/super_diff/operational_sequencers/object.rb +96 -0
  49. data/lib/super_diff/operational_sequencers.rb +5 -0
  50. data/lib/super_diff/operations/binary_operation.rb +47 -0
  51. data/lib/super_diff/operations/unary_operation.rb +25 -0
  52. data/lib/super_diff/rspec/differ.rb +30 -0
  53. data/lib/super_diff/rspec/monkey_patches.rb +122 -0
  54. data/lib/super_diff/rspec.rb +19 -0
  55. data/lib/super_diff/value_inspection.rb +11 -0
  56. data/lib/super_diff/version.rb +3 -0
  57. data/lib/super_diff.rb +50 -0
  58. data/spec/examples.txt +46 -0
  59. data/spec/integration/rspec_spec.rb +261 -0
  60. data/spec/spec_helper.rb +44 -0
  61. data/spec/support/color_helper.rb +49 -0
  62. data/spec/support/command_runner.rb +279 -0
  63. data/spec/support/integration/matchers/produce_output_when_run_matcher.rb +76 -0
  64. data/spec/support/person.rb +23 -0
  65. data/spec/support/person_diff_formatter.rb +15 -0
  66. data/spec/support/person_operation_sequence.rb +14 -0
  67. data/spec/support/person_operational_sequencer.rb +19 -0
  68. data/spec/unit/equality_matcher_spec.rb +1233 -0
  69. data/super_diff.gemspec +23 -0
  70. metadata +153 -0
@@ -0,0 +1,23 @@
1
+ require File.expand_path("../lib/super_diff/version", __FILE__)
2
+
3
+ Gem::Specification.new do |s|
4
+ s.name = "super_diff"
5
+ s.version = SuperDiff::VERSION
6
+ s.authors = ["Elliot Winkler"]
7
+ s.email = ["elliot.winkler@gmail.com"]
8
+ s.homepage = "https://github.com/mcmire/super_diff"
9
+ s.summary = "Diff complex data structures in Ruby, with helpful output."
10
+ s.description = <<~DESC
11
+ SuperDiff is a utility that helps you diff two complex data structures in
12
+ Ruby, and gives you helpful output to show you exactly how the two data
13
+ structures differ.
14
+ DESC
15
+ s.required_ruby_version = "~> 2.3"
16
+
17
+ s.files = ["README.md", "super_diff.gemspec"] + Dir["lib/**/*"]
18
+ s.test_files = Dir["spec/**/*"]
19
+ s.executables = Dir["exe/**/*"].map { |f| File.basename(f) }
20
+
21
+ s.add_dependency "diff-lcs"
22
+ s.add_dependency "patience_diff"
23
+ end
metadata ADDED
@@ -0,0 +1,153 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: super_diff
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Elliot Winkler
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2018-10-03 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: diff-lcs
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: patience_diff
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ description: |
42
+ SuperDiff is a utility that helps you diff two complex data structures in
43
+ Ruby, and gives you helpful output to show you exactly how the two data
44
+ structures differ.
45
+ email:
46
+ - elliot.winkler@gmail.com
47
+ executables: []
48
+ extensions: []
49
+ extra_rdoc_files: []
50
+ files:
51
+ - README.md
52
+ - lib/super_diff.rb
53
+ - lib/super_diff/csi.rb
54
+ - lib/super_diff/csi/color_helper.rb
55
+ - lib/super_diff/csi/eight_bit_color.rb
56
+ - lib/super_diff/csi/eight_bit_sequence.rb
57
+ - lib/super_diff/csi/four_bit_color.rb
58
+ - lib/super_diff/csi/four_bit_sequence.rb
59
+ - lib/super_diff/csi/reset_sequence.rb
60
+ - lib/super_diff/csi/sequence.rb
61
+ - lib/super_diff/csi/twenty_four_bit_color.rb
62
+ - lib/super_diff/csi/twenty_four_bit_sequence.rb
63
+ - lib/super_diff/diff_formatter.rb
64
+ - lib/super_diff/diff_formatters.rb
65
+ - lib/super_diff/diff_formatters/array.rb
66
+ - lib/super_diff/diff_formatters/base.rb
67
+ - lib/super_diff/diff_formatters/collection.rb
68
+ - lib/super_diff/diff_formatters/hash.rb
69
+ - lib/super_diff/diff_formatters/multi_line_string.rb
70
+ - lib/super_diff/diff_formatters/object.rb
71
+ - lib/super_diff/differ.rb
72
+ - lib/super_diff/differs.rb
73
+ - lib/super_diff/differs/array.rb
74
+ - lib/super_diff/differs/base.rb
75
+ - lib/super_diff/differs/empty.rb
76
+ - lib/super_diff/differs/hash.rb
77
+ - lib/super_diff/differs/multi_line_string.rb
78
+ - lib/super_diff/differs/object.rb
79
+ - lib/super_diff/equality_matcher.rb
80
+ - lib/super_diff/equality_matchers.rb
81
+ - lib/super_diff/equality_matchers/array.rb
82
+ - lib/super_diff/equality_matchers/base.rb
83
+ - lib/super_diff/equality_matchers/hash.rb
84
+ - lib/super_diff/equality_matchers/multi_line_string.rb
85
+ - lib/super_diff/equality_matchers/object.rb
86
+ - lib/super_diff/equality_matchers/single_line_string.rb
87
+ - lib/super_diff/errors.rb
88
+ - lib/super_diff/helpers.rb
89
+ - lib/super_diff/operation_sequences/array.rb
90
+ - lib/super_diff/operation_sequences/base.rb
91
+ - lib/super_diff/operation_sequences/hash.rb
92
+ - lib/super_diff/operation_sequences/object.rb
93
+ - lib/super_diff/operational_sequencer.rb
94
+ - lib/super_diff/operational_sequencers.rb
95
+ - lib/super_diff/operational_sequencers/array.rb
96
+ - lib/super_diff/operational_sequencers/base.rb
97
+ - lib/super_diff/operational_sequencers/hash.rb
98
+ - lib/super_diff/operational_sequencers/multi_line_string.rb
99
+ - lib/super_diff/operational_sequencers/object.rb
100
+ - lib/super_diff/operations/binary_operation.rb
101
+ - lib/super_diff/operations/unary_operation.rb
102
+ - lib/super_diff/rspec.rb
103
+ - lib/super_diff/rspec/differ.rb
104
+ - lib/super_diff/rspec/monkey_patches.rb
105
+ - lib/super_diff/value_inspection.rb
106
+ - lib/super_diff/version.rb
107
+ - spec/examples.txt
108
+ - spec/integration/rspec_spec.rb
109
+ - spec/spec_helper.rb
110
+ - spec/support/color_helper.rb
111
+ - spec/support/command_runner.rb
112
+ - spec/support/integration/matchers/produce_output_when_run_matcher.rb
113
+ - spec/support/person.rb
114
+ - spec/support/person_diff_formatter.rb
115
+ - spec/support/person_operation_sequence.rb
116
+ - spec/support/person_operational_sequencer.rb
117
+ - spec/unit/equality_matcher_spec.rb
118
+ - super_diff.gemspec
119
+ homepage: https://github.com/mcmire/super_diff
120
+ licenses: []
121
+ metadata: {}
122
+ post_install_message:
123
+ rdoc_options: []
124
+ require_paths:
125
+ - lib
126
+ required_ruby_version: !ruby/object:Gem::Requirement
127
+ requirements:
128
+ - - "~>"
129
+ - !ruby/object:Gem::Version
130
+ version: '2.3'
131
+ required_rubygems_version: !ruby/object:Gem::Requirement
132
+ requirements:
133
+ - - ">="
134
+ - !ruby/object:Gem::Version
135
+ version: '0'
136
+ requirements: []
137
+ rubyforge_project:
138
+ rubygems_version: 2.7.6
139
+ signing_key:
140
+ specification_version: 4
141
+ summary: Diff complex data structures in Ruby, with helpful output.
142
+ test_files:
143
+ - spec/spec_helper.rb
144
+ - spec/unit/equality_matcher_spec.rb
145
+ - spec/examples.txt
146
+ - spec/integration/rspec_spec.rb
147
+ - spec/support/person_operational_sequencer.rb
148
+ - spec/support/integration/matchers/produce_output_when_run_matcher.rb
149
+ - spec/support/person_diff_formatter.rb
150
+ - spec/support/command_runner.rb
151
+ - spec/support/person_operation_sequence.rb
152
+ - spec/support/person.rb
153
+ - spec/support/color_helper.rb