Add testcases for setLogLevel (#947).
This commit is contained in:
parent
5443363de4
commit
af10705632
@ -626,6 +626,17 @@ describe("BigNumber", function() {
|
|||||||
describe("Logger", function() {
|
describe("Logger", function() {
|
||||||
const logger = new ethers.utils.Logger("testing/0.0");
|
const logger = new ethers.utils.Logger("testing/0.0");
|
||||||
|
|
||||||
|
it ("setLogLevel", function() {
|
||||||
|
ethers.utils.Logger.setLogLevel(ethers.utils.Logger.levels.DEBUG);
|
||||||
|
ethers.utils.Logger.setLogLevel(ethers.utils.Logger.levels.INFO);
|
||||||
|
ethers.utils.Logger.setLogLevel(ethers.utils.Logger.levels.WARNING);
|
||||||
|
ethers.utils.Logger.setLogLevel(ethers.utils.Logger.levels.ERROR);
|
||||||
|
ethers.utils.Logger.setLogLevel(ethers.utils.Logger.levels.OFF);
|
||||||
|
|
||||||
|
// Reset back to INFO when done tests
|
||||||
|
ethers.utils.Logger.setLogLevel(ethers.utils.Logger.levels.INFO);
|
||||||
|
});
|
||||||
|
|
||||||
it("checkArgumentCount", function() {
|
it("checkArgumentCount", function() {
|
||||||
logger.checkArgumentCount(3, 3);
|
logger.checkArgumentCount(3, 3);
|
||||||
});
|
});
|
||||||
@ -647,6 +658,7 @@ describe("Logger", function() {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
describe("Base58 Coder", function() {
|
describe("Base58 Coder", function() {
|
||||||
it("decodes", function() {
|
it("decodes", function() {
|
||||||
|
Loading…
Reference in New Issue
Block a user