Update tests to use jest (#11)

This commit is contained in:
Jaco Greeff
2017-11-21 21:28:20 +01:00
committed by GitHub
parent c4d7aba961
commit 87dd31f72a
17 changed files with 2633 additions and 483 deletions
+2 -2
View File
@@ -2,8 +2,8 @@
Utility methods to convert to and from `BN` objects
- (bnFromHex)[#bnFromHex] Creates a BN.js bignumber object from a hex string.
- (bnToHex)[#bnToHex] Creates a hex value from a BN.js bignumber object.
- [bnFromHex](#bnFromHex) Creates a BN.js bignumber object from a hex string.
- [bnToHex](#bnToHex) Creates a hex value from a BN.js bignumber object.
## bnFromHex
+2 -2
View File
@@ -2,8 +2,8 @@
Utility methods to convert to and from `Buffer` objects
- (bufferFromHex)[#bufferFromHex] Creates a Buffer object from a hex string.
- (bufferToHex)[#bufferToHex] Creates a hex value from a Buffer object.
- [bufferFromHex](#bufferFromHex) Creates a Buffer object from a hex string.
- [bufferToHex](#bufferToHex) Creates a hex value from a Buffer object.
## bufferFromHex
+3 -3
View File
@@ -2,9 +2,9 @@
Internal utilities to create and test for hex values
- (hexAddPrefix)[#hexAddPrefix] Adds the `0x` prefix to string values.
- (hexHasPrefix)[#hexHasPrefix] Tests for the existence of a `0x` prefix.
- (hexStripPrefix)[#hexStripPrefix] Strips any leading `0x` prefix.
- [hexAddPrefix](#hexAddPrefix) Adds the `0x` prefix to string values.
- [hexHasPrefix](#hexHasPrefix) Tests for the existence of a `0x` prefix.
- [hexStripPrefix](#hexStripPrefix) Strips any leading `0x` prefix.
## hexAddPrefix
+8 -8
View File
@@ -2,14 +2,14 @@
Type checking utilities
- (isBN)[#isBN] Tests for a `BN` object instance.
- (isBuffer)[#isBuffer] Tests for a `Buffer` object instance.
- (isFunction)[#isFunction] Tests for a `function`.
- (isHex)[#isHex] Tests for a hex string.
- (isInstanceOf)[#isInstanceOf] Tests for a instance of a class.
- (isNumber)[#isNumber] Tests for a JavaScript number.
- (isString)[#isString] Tests for a string.
- (isUndefined)[#isUndefined] Tests for a `undefined` values.
- [isBN](#isBN) Tests for a `BN` object instance.
- [isBuffer](#isBuffer) Tests for a `Buffer` object instance.
- [isFunction](#isFunction) Tests for a `function`.
- [isHex](#isHex) Tests for a hex string.
- [isInstanceOf](#isInstanceOf) Tests for a instance of a class.
- [isNumber](#isNumber) Tests for a JavaScript number.
- [isString](#isString) Tests for a string.
- [isUndefined](#isUndefined) Tests for a `undefined` values.
## isBN
+1 -1
View File
@@ -2,7 +2,7 @@
Convenience functions for values from @polkadot/jsonrpc
- (jsonrpcSignature)[#jsonrpcSignature] Returns a string representation of the method with inputs and outputs.
- [jsonrpcSignature](#jsonrpcSignature) Returns a string representation of the method with inputs and outputs.
## jsonrpcSignature
+3 -3
View File
@@ -2,9 +2,9 @@
Create Keccak256 values as hex, string & buffer output
- (keccakAsBuffer)[#keccakAsBuffer] Creates a keccak Buffer from the input.
- (keccakAsHex)[#keccakAsHex] Creates a keccak hex string from the input.
- (keccakAsString)[#keccakAsString] Creates a keccak string from the input.
- [keccakAsBuffer](#keccakAsBuffer) Creates a keccak Buffer from the input.
- [keccakAsHex](#keccakAsHex) Creates a keccak hex string from the input.
- [keccakAsString](#keccakAsString) Creates a keccak string from the input.
## keccakAsBuffer