Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace usages of assertFileOccurences by usage of new functions ✨ (4/n) #444

Merged
merged 3 commits into from
Nov 9, 2023

Conversation

smelc
Copy link
Contributor

@smelc smelc commented Nov 8, 2023

Changelog

- description: |
    Replace usages of assertFileOccurences by usage of new functions 
# uncomment types applicable to the change:
  type:
  # - feature        # introduces a new feature
  # - breaking       # the API has changed in a breaking way
  # - compatible     # the API has changed but is non-breaking
  # - optimisation   # measurable performance improvements
  # - improvement    # QoL changes e.g. refactoring
  # - bugfix         # fixes a defect
  - test           # fixes/modifies tests
  # - maintenance    # not directly related to the code
  # - release        # related to a new release preparation
  # - documentation  # change in code docs, haddocks...

Context

  • Contributes to fixing assertFileOccurences doesn't check CBOR payload #415
  • Contrary to previous PRs, this one doesn't introduce golden files: instead it makes some existing tests that have nondeterministic content more precise.
  • I did that, because - during the previous PRs -, I witnessed some tests that could be enhanced.

How to trust this PR

  • The new assert* functions try to be helpful and provide good error messages
  • The new assert* functions are specialized to JSON string->string mappings. That is intended, to make their usage easy and the tests easy to read.

Checklist

  • Commit sequence broadly makes sense and commits have useful messages
  • New tests are added if needed and existing tests are updated. See Running tests for more details
  • Self-reviewed the diff

@smelc smelc force-pushed the smelc/fix-assert-file-occurences-4 branch 2 times, most recently from b6c183c to 2f50585 Compare November 8, 2023 15:04
@smelc smelc marked this pull request as ready for review November 8, 2023 15:05
@smelc smelc force-pushed the smelc/fix-assert-file-occurences-4 branch from 855cd3c to 33f7238 Compare November 9, 2023 09:43
@smelc
Copy link
Contributor Author

smelc commented Nov 9, 2023

Thanks @carbolymer, change done in all functions 👍

@smelc smelc enabled auto-merge November 9, 2023 09:44
@smelc smelc added this pull request to the merge queue Nov 9, 2023
Merged via the queue into main with commit 9382929 Nov 9, 2023
19 checks passed
@smelc smelc deleted the smelc/fix-assert-file-occurences-4 branch November 9, 2023 10:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants