Commit 556259d
authored
[Ruby] Split messages files per message type (#225)
* Set minimum ruby to 2.7 and minimum rubygems to 3.2.3
* Remove ruby 2.6 and 2.7 from workflows - Add in ruby 3.3
* Update target rubocop version
* Update misc files
* Update to use latest CCK in testing
* Remove some gitignore files
* Spike of non-working code
* Spike of using both private and public methods
* Compare / contrast the two ways of performing the new cck path reference
* Working example for iterative checks on each item
* Use file exist to simplify code - Remove wildcards
* Update minimum deps for rake / rspec
* Fix up all gemspec cops
* Move towards a spec support structure to remove any oddities flagged by rubocop
* Remove duplicate dummy messages
* Split up composiite dummy message class into individual items
* Remove top level leaked fake class for utils testing
* Fix up some minor simple offenses for utils spec
* Slight update to check rubocop works and then regenerate autogenconfig
* Bump rubocop performance and rubocop rake to latest. Slight bump to rubocop / rubocop-rspec
* Fix up issue whereby error was being rescued incorrectly and was being stored without requirement
* Tidy up serialization formatting
* Ignore line length cop as it's un-enforceable
* Attempt to distinguish what are the actual objects in the acceptance tests
* Re-gen the autogen config using bundler to ensure correct version (For now)
* Set minimum ruby to 3.0
* Reduce line count of spec for acceptance as we just want a wrap/unwrap call
* Fix up typos and named subject issue in serialization spec
* Fix up a couple of spec support Lint/MissingSuper calls
* Simplify deserialization protocol into just a single class method which is extended
* underscore as a method isn't used in the utils implementation
* Remove underscore tests
* Simplify Utils to just be extended as class methods
* Utils aren't used in the deserialization protocol
* Move all serialization into the message proper as it's just a single module with 1 method used in 1 location
* Move the deserialization spec tests into message proper
Fix describe block as they're class methods not instance methods
* Remove utils class and place camelize inside the message proper
* Don't create an extra object
* Split id generator into individual class files
* AF: Style/SpecialGlobalVars
* Simplify serialization spec by not creating 10 different subjects
* AF: Gemspec/OrderedDependencies
* AF: Layout/EmptyLineAfterMagicComment
* Partial fix for the Layout/FirstArrayElementIndentation cop offenses
* AF: Layout/LeadingEmptyLines
* Re-generate todo file with May's marker - 50 offenses cleared with the gem upgrade and rubocop bump
* Fix rubocop error
* Alter UUID test to just check for a securerandom uuid and simplify the code
* Alter incrementing spec to only have 1 assertion line
* Move serialization into message model proper
* Fix up Layout cops after copying over serialization messages
* AF: Lint/ToJSON should allow optional discarded args
* In ruby 2.6+ #to_h permits a block assign so we can refine this code better
* Refine the compacting of the resultant hash in the message adhering to the Style/CollectionCompact rule
* AF: Style/SlicingWithRange
* Update tests to remove redundant failing ones and fix up some legacy named subject offenses
* Re-order and tidy up messages class
* Add super() call to each message generation - Should remedy Lint/MissingSuper cop offense
* Re-generate config
* Fix up args to JSONSchema generation to use Ruby 3.0+ idioms
* Fix up the Trailing Whitespace cop by fixing a generation bug
* AF: Lint/AmbiguousOperatorPrecedence
* Fix up RSpec/DescribedClass issue with ndjson spec
* Partial fix of RSpec/ExampleLength
* Alter the Enum generator enabling us to autofix Style/ClassAndModuleChildren
* AF: FrozenStringLiteral
* Remove redundant spec
* Configure and permit AllowedNames to also include as a name and Exclusion lists to be merged
* Disable Style/AccessorGrouping
* Fix up namespacing issues when migrating tests
* Move some logic out into let/subject blocks
* Fix up auto-fix offenses in rubocop
* Remove frozen string literal pragma's whilst we haven't fixed up autogen
* Add new requirements pending migration to one class per file logic like in java/cpp
* Fix up line spacing in generic ruby file and begin to split file into constituent ones
* Move all helpers to helpers namespace
* Fix up tests and require path
* Rename confusingly named make targets
* Generate files in new way
* Leave leakage item on dtos file for now as it will serve well when we come to fix filename
* Add new generation logic to .generate-messages
* add new clean command
* Add new filename checking for template
Fix clean process not to remove helpers
* Alter generation to use snake cased names
* Re-generate files
* Remove extra line that's not needed
* Make inheritance from message simpler
* Alter enum generation to also make new unique files
* Add .from_h method to ruby.rb.erb template to begin process of removing redundant template
* Add enum generation to the generator script
Clean up all redundant strings
* Remove all trace to referencing the .dtos.rb file including using the now un-needed jsonschema template for the deserializers
* Remove all trace to referencing the .deserializers.rb file
* Fix up namespace for UUID
* Require all new messages when requiring one message
* Only add comma after properties that aren't final
* Remove un-required requirement now we are recursively loading items in
* Re-generate messages using new templates
* Remove duplicate comma on the if/elsif/else statement
* Add comma into correct spot in template
* Fixed mismatched comment style from template
* Fix frozen string literal pragmas in templates
* Enum template was assigning an un-needed index during iteration
* Re-generated messages
* Re-generate TODO file after minor fixes in templates
* AF: Style/StringConcatenation
* Manual fix for RSpec/ExampleLength
* AF: RSpec/DescribedClass£
* AF: Layout/SpaceInsideBlockBraces
* Remove duplicate files missed by bad merge conflict
* Re-generate TODO file owing to conflict clash
* Fix up RSpec/MultipleExpectations
* Disable ParameterLists cop as most messages will have 5+ properties
* Fix up RSpec/NestedGroups
* Ignore method length for same reason as parameter lists
* AF: Layout/EmptyLineAfterGuardClause
* Remove TODO file as we have < 10 offenses to fix now
* Ignore all generated files
* Switch from metric blanket overrides to generated code overrides
* Only ignore Metrics and Layout/LineLength for generated messages
* Fix up line length offenses in message class proper
* Fix up all remaining line length issues in the specs
* Fix up LineLength offenses by moving extraction of message out to a private sub method
* Update changelogs
* Slight update to some rubocop gems that don't affect signoff of rubocop conformance
* Accessor grouping should only be unenforceable in generated messages
* Update docs1 parent 4a2c5fe commit 556259d
91 files changed
Lines changed: 3501 additions & 3413 deletions
File tree
- jsonschema/scripts/templates
- ruby
- lib/cucumber
- messages
- helpers
- id_generator
- id_generator
- spec
- cucumber/messages
- helpers
- id_generator
- support
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | | - | |
| 13 | + | |
13 | 14 | | |
14 | 15 | | |
15 | 16 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
23 | | - | |
| 23 | + | |
| 24 | + | |
24 | 25 | | |
25 | 26 | | |
26 | | - | |
| 27 | + | |
| 28 | + | |
27 | 29 | | |
28 | 30 | | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
| 31 | + | |
36 | 32 | | |
37 | 33 | | |
38 | 34 | | |
39 | | - | |
| 35 | + | |
| 36 | + | |
40 | 37 | | |
41 | 38 | | |
42 | 39 | | |
43 | | - | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
59 | | - | |
60 | | - | |
| 59 | + | |
| 60 | + | |
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
| |||
78 | 78 | | |
79 | 79 | | |
80 | 80 | | |
81 | | - | |
| 81 | + | |
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
88 | | - | |
89 | | - | |
| 88 | + | |
90 | 89 | | |
91 | 90 | | |
92 | 91 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
1 | 4 | | |
2 | | - | |
| 5 | + | |
3 | 6 | | |
4 | 7 | | |
5 | 8 | | |
6 | | - | |
| 9 | + | |
7 | 10 | | |
8 | 11 | | |
9 | 12 | | |
10 | 13 | | |
11 | 14 | | |
12 | | - | |
13 | | - | |
| 15 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
| 2 | + | |
| 3 | + | |
2 | 4 | | |
3 | 5 | | |
4 | | - | |
5 | | - | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
9 | 8 | | |
10 | 9 | | |
| 10 | + | |
11 | 11 | | |
12 | | - | |
| 12 | + | |
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
33 | 60 | | |
34 | | - | |
35 | 61 | | |
36 | 62 | | |
| 63 | + | |
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | | - | |
3 | 1 | | |
4 | 2 | | |
5 | 3 | | |
| |||
17 | 15 | | |
18 | 16 | | |
19 | 17 | | |
20 | | - | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
21 | 25 | | |
22 | | - | |
| 26 | + | |
| 27 | + | |
23 | 28 | | |
24 | 29 | | |
25 | 30 | | |
| |||
31 | 36 | | |
32 | 37 | | |
33 | 38 | | |
34 | | - | |
| 39 | + | |
| 40 | + | |
35 | 41 | | |
36 | 42 | | |
37 | 43 | | |
| |||
This file was deleted.
0 commit comments