Esteban Ordano
ea17a6ace1
Add a preconditions module, and refactor errors
100% code coverage for the preconditions module.
Usage:
```
$.checkState(something === anotherthing, 'Expected something to be
anotherthing');
$.checkArgument(something < 100, 'something', 'must be less than 100');
$.checkArgumentType(something, PrivateKey, 'something'); // The third
argument is a helper to mention the name of the argument
$.checkArgumentType(something, PrivateKey); // but it's optional (will
show up as "(unknown argument)")
```
10 years ago
Esteban Ordano
1816ba197f
Add check functions to Address
10 years ago
Manuel Araoz
ec00ccba4c
add script public key hash in tests
10 years ago
Esteban Ordano
736bcd6bd4
Backport changes to ecdsa from fullnode
10 years ago
Esteban Ordano
f8397a617e
Add option to create private key from hex
10 years ago
Esteban Ordano
baf6a24d23
Add ".publicKey" property to PrivateKey
10 years ago
Braydon Fuller
5d1da9802c
Block: Added validation of proof of work, merkle tree and other interface changes. Closes #601
10 years ago
Manuel Araoz
f231f8a054
fix a browser test 2
10 years ago
Manuel Araoz
6c5198b743
fix a browser test
10 years ago
Manuel Araoz
eaaab5c7d0
implement Script.buildScriptHashOut()
10 years ago
Manuel Araoz
4bca5316ea
implement Script.buildDDataOut()
10 years ago
Manuel Araoz
b87e687fd9
implement Script.buildPublicKeyHashOut()
10 years ago
Manuel Araoz
7b54a53414
add Opcode.smallInt()
10 years ago
Manuel Araoz
4fae69807d
change isOpReturn to isDataOut
10 years ago
Manuel Araoz
d05aa27bed
finish all tests
10 years ago
Braydon Fuller
ae80ca8678
PublicKey: Add test to verify that both uncompressed an compressed keys validatate. Fixes #665
10 years ago
Braydon Fuller
64c0d5f942
Payment Protocol: Restore and reorganize files for payment protocol.
10 years ago
Manuel Araoz
ef8f1eabd2
add script.isStandard()
10 years ago
Manuel Araoz
883a7cae54
add unkown script test
10 years ago
Manuel Araoz
c4cc6ba56d
fix tests with new script api
10 years ago
Manuel Araoz
87c40193b9
add pubkey in pubkey out script types
10 years ago
Manuel Araoz
901d55d129
fix classify tests
10 years ago
Manuel Araoz
7d9151abc6
fix classify tests
10 years ago
Manuel Araoz
9d6ff4dc44
add classify tests
10 years ago
Manuel Araoz
293a3299d4
add classify tests
10 years ago
Manuel Araoz
72b5dcc6af
add Script.isMultisigIn
10 years ago
Manuel Araoz
96e1451d28
add script.isMultisigOut
10 years ago
Manuel Araoz
350816ad40
opcode refactor: isSmallIntOp
10 years ago
Manuel Araoz
4a6755d0d1
add Script#prepend()
10 years ago
Manuel Araoz
66e96e5fa4
make tests pass with Script refactor
10 years ago
Braydon Fuller
d5d88287cd
Networks: Consistency of network reference for 'livenet', and removed hardcoded value.
10 years ago
Esteban Ordano
3dbb35a708
Fixes build, add "mainnet" again and fixes uri
10 years ago
Braydon Fuller
4ba53fcb92
Tests: Check that PrivateKey is using the defaultNetwork
10 years ago
Braydon Fuller
2cbcf7da1c
Tests: Check that an Address is using the defaultNetwork
10 years ago
Braydon Fuller
6e36baebc6
Tests: Enable tests for network, include defaultNetwork, check each constant, build browser tests before running to make sure it's up-to-date
10 years ago
Braydon Fuller
4adf1fcb14
Network: Replaced all instances of mainnet with livenet for consistency
10 years ago
Yemel Jardi
9cd9eeba1f
convert amout to satoshis
10 years ago
Yemel Jardi
c9951be2dc
Base URI class and tests
10 years ago
Braydon Fuller
b06866f86f
PublicKey: Added toAddress prototype. Closes #599
10 years ago
Yemel Jardi
1ae88eed7a
Add new test for string values
10 years ago
Yemel Jardi
ab517cae9c
refactor double quote
10 years ago
Braydon Fuller
3298a01498
Immutable Address, PublicKey and PrivateKey
10 years ago
Yemel Jardi
d978160ddb
Utility for unit conversion
10 years ago
Braydon Fuller
9a76bf30ff
Crypto/Point: Added test coverage and documentation, and refactored validation
10 years ago
Esteban Ordano
865a69f6f2
add testing for key cache
10 years ago
Esteban Ordano
13fd2592fc
Add autogenerated errors
10 years ago
Esteban Ordano
803027353a
Change errors
10 years ago
Esteban Ordano
a2a51ecc0c
Fix style: move each static function to an appropiate namespace
10 years ago
Esteban Ordano
53900f3196
Add cache to derivation
10 years ago
Esteban Ordano
4c0769fa09
100% test coverage on hdpublickey
10 years ago