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

Verify transactions in a block are well formed #4504

Merged
merged 1 commit into from Oct 31, 2023

Conversation

yacovm
Copy link
Contributor

@yacovm yacovm commented Oct 29, 2023

Verify that transactions in blocks appear exactly as their marshaled form after unmarshaling.

},
{
name: "transaction invalid",
expectedError: "cannot parse invalid wire-format data",
Copy link
Contributor

Choose a reason for hiding this comment

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

In release-2.2, I had to change this to "illegal tag 0 (wire type 6)" to get unit test to pass due to the older dependencies.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes I can see that much, from the output:


--- FAIL: TestVerifyTransactionsAreWellFormed (0.00s)
    --- FAIL: TestVerifyTransactionsAreWellFormed/transaction_invalid (0.00s)
        blockutils_test.go:502: 
            	Error Trace:	blockutils_test.go:502
            	Error:      	"transaction 0 is invalid: proto: common.Envelope: illegal tag 0 (wire type 6)" does not contain "cannot parse invalid wire-format data"
            	Test:       	TestVerifyTransactionsAreWellFormed/transaction_invalid

@yacovm yacovm force-pushed the wellForm-2.2 branch 2 times, most recently from d4c6ca2 to 34eed3a Compare October 30, 2023 21:08
Verify that transactions in blocks appear exactly as their marshaled form after unmarshaling.

Signed-off-by: Yacov Manevich <yacov.manevich@ibm.com>
@denyeart denyeart merged commit 389b2e6 into hyperledger:release-2.2 Oct 31, 2023
12 of 13 checks passed
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.

None yet

3 participants