-
Notifications
You must be signed in to change notification settings - Fork 113
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
Problem: missing property-base testing (fix #857) #862
base: dev
Are you sure you want to change the base?
Conversation
import sdk from '@crypto-org-chain/chain-jslib'; | ||
import { Units, Secp256k1KeyPair } from '../../utils/ChainJsLib'; | ||
|
||
test('should declare coin in ledger correctly', () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what's the property here? cro.Coin
not throwing an exception?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
whether coin can be created to the maximum, that will not throw any exception
}, | ||
phrase, | ||
); | ||
expect(transferTxSignedHex !== '').to.eq(true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could also check transferTxSignedHex
can be parsed into a transaction?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
package.json
There are also some
|
fixing lint issue |
9f199ae
to
5c6a7fb
Compare
add fast-check testing add tx rlp decoding tidy up fix lint and tidy up fix lint remove else
9c2619c
to
36a7219
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
checked
); | ||
const decodedTransaction = RLP.decode(transferTxSignedHex); | ||
expect(transferTxSignedHex !== '').to.eq(true); | ||
expect(BigInt(decodedTransaction[4]) === amount).to.eq(true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- [ ]
}, | ||
phrase, | ||
); | ||
expect(transferTxSignedHex !== '').to.eq(true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
package.json
}, | ||
phrase, | ||
); | ||
const decodedTransaction = RLP.decode(transferTxSignedHex); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- [ ]
phrase, | ||
); | ||
const decodedTransaction = RLP.decode(transferTxSignedHex); | ||
expect(transferTxSignedHex !== '').to.eq(true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- (True)
add fast-check testing