Closed timur-harin closed 3 months ago
@yegor256 Please check this important PR for metrics
@timur-harin looks good! However, you broke the structure that we use in all our tests. Don't go outside of the {...}
layout and don't make your own error message. Just exit 1
if the test fails. Also, don't modify an existing test, but add your own new test at the bottom.
@yegor256 But we had to remove expected in this file what I discussed in Issue #282
So you suggest creating another file test-number-of-metrics.sh
with the same logic and return everything back in test-measure-file.sh
besides analysing the number of metrics?
@timur-harin no need to create a new file. Just take the test-measure-file.sh
file, remove the line where we check the number of metrics and commit. Then, add a new test at the bottom of this file -- the test that you created.
@yegor256 I applied your suggestions:
ππ» Number of metrics matches for simple and complex Java files: 62 metrics
@timur-harin excellent work, thanks!
@yegor256 In this PR, I added:
Now the result of
sudo make test TEST=tests/steps/test-measure-file.sh