File tree Expand file tree Collapse file tree 1 file changed +18
-4
lines changed
Expand file tree Collapse file tree 1 file changed +18
-4
lines changed Original file line number Diff line number Diff line change 260260 calculator = RailsStats ::StatsCalculator . new ( root_directory )
261261 formatter = RailsStats ::JSONFormatter . new ( calculator )
262262
263- sorted_expectation = JSON . parse ( JSON_STRING )
264- sorted_result = formatter . result
263+ expectation = JSON . parse ( JSON_STRING )
264+ result = formatter . result
265265
266- sorted_expectation . each_with_index do |x , i |
267- assert_equal x , sorted_result [ i ]
266+ expectation . each do |hash |
267+ if hash [ "gems" ]
268+ hash [ "gems" ] . each do |gem |
269+ gem [ "transitive_dependencies" ] &.sort!
270+ end
271+ end
268272 end
273+
274+ result . each do |hash |
275+ if hash [ "gems" ]
276+ hash [ "gems" ] . each do |gem |
277+ gem [ "transitive_dependencies" ] &.sort!
278+ end
279+ end
280+ end
281+
282+ assert_equal expectation , result
269283 end
270284 end
271285end
You can’t perform that action at this time.
0 commit comments