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

test(ethereum): refactor jest test negative test cases #3476

Conversation

ashnashahgrover
Copy link
Contributor

@ashnashahgrover ashnashahgrover commented Aug 12, 2024

Commit to be reviewed

test(ethereum): refactor jest test negative test cases

Primary Changes
---------------
1. Refactored negative test case exception assertions for cactus-plugin-ledger-connector-ethereum.
Removed try-catch blocks, replaced with declarations through jest-extended's own API.
2. Made comments on specific tests where the tests should fail but are actually passing 
and thus cannot be refactored before being investigated further. 

Fixes #3475

Pull Request Requirements

  • Rebased onto upstream/main branch and squashed into single commit to help maintainers review it more efficient and to avoid spaghetti git commit graphs that obfuscate which commit did exactly what change, when and, why.
  • Have git sign off at the end of commit message to avoid being marked red. You can add -s flag when using git commit command. You may refer to this link for more information.
  • Follow the Commit Linting specification. You may refer to this link for more information.

Character Limit

  • Pull Request Title and Commit Subject must not exceed 72 characters (including spaces and special characters).
  • Commit Message per line must not exceed 80 characters (including spaces and special characters).

A Must Read for Beginners
For rebasing and squashing, here's a must read guide for beginners.

Copy link
Contributor

@petermetz petermetz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ashnashahgrover LGTM with comments

Copy link
Contributor

@RafaelAPB RafaelAPB left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Besides Peter's comments, LGTM!

@ashnashahgrover ashnashahgrover force-pushed the ashnashahgrover/issue3475 branch 2 times, most recently from 1280003 to f01487a Compare August 18, 2024 20:27
@petermetz
Copy link
Contributor

@ashnashahgrover Please fix the lint check and then we are good to merge

@ashnashahgrover
Copy link
Contributor Author

ashnashahgrover commented Sep 3, 2024

@ashnashahgrover Please fix the lint check and then we are good to merge

This is done @petermetz

Copy link
Contributor

@petermetz petermetz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ashnashahgrover Looks like it is still failing on the CI unfortunately. Another thing: Please rebase and squash the commits instead of putting merge commits on the PR (right now it has 2 commits, it should only have the 1 which is the actual change)

image

Primary Changes
---------------
1. Refactored negative test case exception assertions for cactus-plugin-ledger-connector-ethereum.
Removed try-catch blocks, replaced with declarations through jest-extended's own API.
2. Made comments on specific tests where the tests should fail but are actually passing
and thus cannot be refactored before being investigated further.
 
Fixes hyperledger-cacti#3475

Signed-off-by: ashnashahgrover <[email protected]>
@petermetz
Copy link
Contributor

Closing this due to inactivity. Happy to reopen it anytime in the future as needed.

@petermetz petermetz closed this Oct 15, 2024
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.

test(ethereum): fix broken validations in tests
3 participants