Skip to main content

DSTest

Functions

fail

function fail() internal

assertTrue

function assertTrue(
bool condition
) internal

Parameters

NameTypeDescription
conditionbool

assertFalse

function assertFalse(
bool condition
) internal

Parameters

NameTypeDescription
conditionbool

assertTrue

function assertTrue(
bool condition,
string err
) internal

Parameters

NameTypeDescription
conditionbool
errstring

assertEq

function assertEq(
address a,
address b
) internal

Parameters

NameTypeDescription
aaddress
baddress

assertEq

function assertEq(
address a,
address b,
string err
) internal

Parameters

NameTypeDescription
aaddress
baddress
errstring

assertEq

function assertEq(
bytes32 a,
bytes32 b
) internal

Parameters

NameTypeDescription
abytes32
bbytes32

assertEq

function assertEq(
bytes32 a,
bytes32 b,
string err
) internal

Parameters

NameTypeDescription
abytes32
bbytes32
errstring

assertEq

function assertEq(
bool a,
bool b
) internal

Parameters

NameTypeDescription
abool
bbool

assertEq32

function assertEq32(
bytes32 a,
bytes32 b
) internal

Parameters

NameTypeDescription
abytes32
bbytes32

assertEq32

function assertEq32(
bytes32 a,
bytes32 b,
string err
) internal

Parameters

NameTypeDescription
abytes32
bbytes32
errstring

assertEq

function assertEq(
int256 a,
int256 b
) internal

Parameters

NameTypeDescription
aint256
bint256

assertEq

function assertEq(
int256 a,
int256 b,
string err
) internal

Parameters

NameTypeDescription
aint256
bint256
errstring

assertEq

function assertEq(
uint256 a,
uint256 b
) internal

Parameters

NameTypeDescription
auint256
buint256

assertEq

function assertEq(
uint256 a,
uint256 b,
string err
) internal

Parameters

NameTypeDescription
auint256
buint256
errstring

assertEqDecimal

function assertEqDecimal(
int256 a,
int256 b,
uint256 decimals
) internal

Parameters

NameTypeDescription
aint256
bint256
decimalsuint256

assertEqDecimal

function assertEqDecimal(
int256 a,
int256 b,
uint256 decimals,
string err
) internal

Parameters

NameTypeDescription
aint256
bint256
decimalsuint256
errstring

assertEqDecimal

function assertEqDecimal(
uint256 a,
uint256 b,
uint256 decimals
) internal

Parameters

NameTypeDescription
auint256
buint256
decimalsuint256

assertEqDecimal

function assertEqDecimal(
uint256 a,
uint256 b,
uint256 decimals,
string err
) internal

Parameters

NameTypeDescription
auint256
buint256
decimalsuint256
errstring

assertGt

function assertGt(
uint256 a,
uint256 b
) internal

Parameters

NameTypeDescription
auint256
buint256

assertGt

function assertGt(
uint256 a,
uint256 b,
string err
) internal

Parameters

NameTypeDescription
auint256
buint256
errstring

assertGt

function assertGt(
int256 a,
int256 b
) internal

Parameters

NameTypeDescription
aint256
bint256

assertGt

function assertGt(
int256 a,
int256 b,
string err
) internal

Parameters

NameTypeDescription
aint256
bint256
errstring

assertGtDecimal

function assertGtDecimal(
int256 a,
int256 b,
uint256 decimals
) internal

Parameters

NameTypeDescription
aint256
bint256
decimalsuint256

assertGtDecimal

function assertGtDecimal(
int256 a,
int256 b,
uint256 decimals,
string err
) internal

Parameters

NameTypeDescription
aint256
bint256
decimalsuint256
errstring

assertGtDecimal

function assertGtDecimal(
uint256 a,
uint256 b,
uint256 decimals
) internal

Parameters

NameTypeDescription
auint256
buint256
decimalsuint256

assertGtDecimal

function assertGtDecimal(
uint256 a,
uint256 b,
uint256 decimals,
string err
) internal

Parameters

NameTypeDescription
auint256
buint256
decimalsuint256
errstring

assertGe

function assertGe(
uint256 a,
uint256 b
) internal

Parameters

NameTypeDescription
auint256
buint256

assertGe

function assertGe(
uint256 a,
uint256 b,
string err
) internal

Parameters

NameTypeDescription
auint256
buint256
errstring

assertGe

function assertGe(
int256 a,
int256 b
) internal

Parameters

NameTypeDescription
aint256
bint256

assertGe

function assertGe(
int256 a,
int256 b,
string err
) internal

Parameters

NameTypeDescription
aint256
bint256
errstring

assertGeDecimal

function assertGeDecimal(
int256 a,
int256 b,
uint256 decimals
) internal

Parameters

NameTypeDescription
aint256
bint256
decimalsuint256

assertGeDecimal

function assertGeDecimal(
int256 a,
int256 b,
uint256 decimals,
string err
) internal

Parameters

NameTypeDescription
aint256
bint256
decimalsuint256
errstring

assertGeDecimal

function assertGeDecimal(
uint256 a,
uint256 b,
uint256 decimals
) internal

Parameters

NameTypeDescription
auint256
buint256
decimalsuint256

assertGeDecimal

function assertGeDecimal(
uint256 a,
uint256 b,
uint256 decimals,
string err
) internal

Parameters

NameTypeDescription
auint256
buint256
decimalsuint256
errstring

assertLt

function assertLt(
uint256 a,
uint256 b
) internal

Parameters

NameTypeDescription
auint256
buint256

assertLt

function assertLt(
uint256 a,
uint256 b,
string err
) internal

Parameters

NameTypeDescription
auint256
buint256
errstring

assertLt

function assertLt(
int256 a,
int256 b
) internal

Parameters

NameTypeDescription
aint256
bint256

assertLt

function assertLt(
int256 a,
int256 b,
string err
) internal

Parameters

NameTypeDescription
aint256
bint256
errstring

assertLtDecimal

function assertLtDecimal(
int256 a,
int256 b,
uint256 decimals
) internal

Parameters

NameTypeDescription
aint256
bint256
decimalsuint256

assertLtDecimal

function assertLtDecimal(
int256 a,
int256 b,
uint256 decimals,
string err
) internal

Parameters

NameTypeDescription
aint256
bint256
decimalsuint256
errstring

assertLtDecimal

function assertLtDecimal(
uint256 a,
uint256 b,
uint256 decimals
) internal

Parameters

NameTypeDescription
auint256
buint256
decimalsuint256

assertLtDecimal

function assertLtDecimal(
uint256 a,
uint256 b,
uint256 decimals,
string err
) internal

Parameters

NameTypeDescription
auint256
buint256
decimalsuint256
errstring

assertLe

function assertLe(
uint256 a,
uint256 b
) internal

Parameters

NameTypeDescription
auint256
buint256

assertLe

function assertLe(
uint256 a,
uint256 b,
string err
) internal

Parameters

NameTypeDescription
auint256
buint256
errstring

assertLe

function assertLe(
int256 a,
int256 b
) internal

Parameters

NameTypeDescription
aint256
bint256

assertLe

function assertLe(
int256 a,
int256 b,
string err
) internal

Parameters

NameTypeDescription
aint256
bint256
errstring

assertLeDecimal

function assertLeDecimal(
int256 a,
int256 b,
uint256 decimals
) internal

Parameters

NameTypeDescription
aint256
bint256
decimalsuint256

assertLeDecimal

function assertLeDecimal(
int256 a,
int256 b,
uint256 decimals,
string err
) internal

Parameters

NameTypeDescription
aint256
bint256
decimalsuint256
errstring

assertLeDecimal

function assertLeDecimal(
uint256 a,
uint256 b,
uint256 decimals
) internal

Parameters

NameTypeDescription
auint256
buint256
decimalsuint256

assertLeDecimal

function assertLeDecimal(
uint256 a,
uint256 b,
uint256 decimals,
string err
) internal

Parameters

NameTypeDescription
auint256
buint256
decimalsuint256
errstring

assertEq

function assertEq(
string a,
string b
) internal

Parameters

NameTypeDescription
astring
bstring

assertEq

function assertEq(
string a,
string b,
string err
) internal

Parameters

NameTypeDescription
astring
bstring
errstring

checkEq0

function checkEq0(
bytes a,
bytes b
) internal returns (bool ok)

Parameters

NameTypeDescription
abytes
bbytes

assertEq0

function assertEq0(
bytes a,
bytes b
) internal

Parameters

NameTypeDescription
abytes
bbytes

assertEq0

function assertEq0(
bytes a,
bytes b,
string err
) internal

Parameters

NameTypeDescription
abytes
bbytes
errstring

Events

log

event log(
string
)

Parameters

NameTypeDescription
``string

logs

event logs(
bytes
)

Parameters

NameTypeDescription
``bytes

log_address

event log_address(
address
)

Parameters

NameTypeDescription
``address

log_bytes32

event log_bytes32(
bytes32
)

Parameters

NameTypeDescription
``bytes32

log_int

event log_int(
int256
)

Parameters

NameTypeDescription
``int256

log_uint

event log_uint(
uint256
)

Parameters

NameTypeDescription
``uint256

log_bytes

event log_bytes(
bytes
)

Parameters

NameTypeDescription
``bytes

log_string

event log_string(
string
)

Parameters

NameTypeDescription
``string

log_named_address

event log_named_address(
string key,
address val
)

Parameters

NameTypeDescription
keystring
valaddress

log_named_bytes32

event log_named_bytes32(
string key,
bytes32 val
)

Parameters

NameTypeDescription
keystring
valbytes32

log_named_decimal_int

event log_named_decimal_int(
string key,
int256 val,
uint256 decimals
)

Parameters

NameTypeDescription
keystring
valint256
decimalsuint256

log_named_decimal_uint

event log_named_decimal_uint(
string key,
uint256 val,
uint256 decimals
)

Parameters

NameTypeDescription
keystring
valuint256
decimalsuint256

log_named_int

event log_named_int(
string key,
int256 val
)

Parameters

NameTypeDescription
keystring
valint256

log_named_uint

event log_named_uint(
string key,
uint256 val
)

Parameters

NameTypeDescription
keystring
valuint256

log_named_bytes

event log_named_bytes(
string key,
bytes val
)

Parameters

NameTypeDescription
keystring
valbytes

log_named_string

event log_named_string(
string key,
string val
)

Parameters

NameTypeDescription
keystring
valstring