31 lines
710 B
TypeScript
31 lines
710 B
TypeScript
|
import {cliTest,createBond} from './helper';
|
||
|
|
||
|
const args= "authority "
|
||
|
|
||
|
var bondId: string;
|
||
|
var name: string;
|
||
|
|
||
|
describe("test authority",() => {
|
||
|
|
||
|
beforeAll(async () => {
|
||
|
// get bond id
|
||
|
bondId=createBond("aphoton","1000000000")
|
||
|
});
|
||
|
|
||
|
|
||
|
it("reserve authority",async ()=>{
|
||
|
name="laconic"
|
||
|
const resp=cliTest(args+"reserve "+name);
|
||
|
expect(resp).toBeDefined;
|
||
|
});
|
||
|
|
||
|
it("lookup authority information.",async ()=>{
|
||
|
const resp=cliTest(args+"whois "+ name);
|
||
|
expect(resp).toBeDefined;
|
||
|
});
|
||
|
|
||
|
it("set authority bond",async ()=>{
|
||
|
const resp=cliTest(args+"bond set "+name+" "+bondId);
|
||
|
expect(resp).toBeDefined;
|
||
|
});
|
||
|
});
|