-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e3facad
commit fc06cad
Showing
4 changed files
with
35 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
const { Blockchain, nameToBigInt } = require("@proton/vert"); | ||
const { assert } = require("chai"); | ||
const blockchain = new Blockchain() | ||
|
||
// Load contract (use paths relative to the root of the project) | ||
const contract = blockchain.createContract('contract', 'build/contract') | ||
|
||
/* Runs before each test */ | ||
beforeEach(async () => { | ||
blockchain.resetTables() | ||
}) | ||
|
||
/* Tests */ | ||
describe('Test', () => { | ||
it('testing', async () => { | ||
const [usera, userb] = blockchain.createAccounts('usera', 'userb') | ||
const result = await contract.actions.newuser(['usera']).send('usera@active') | ||
const rows = contract.tables.users(nameToBigInt('contract')).getTableRow(nameToBigInt('usera')); | ||
assert(!!rows, "User not found") | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,13 @@ | ||
{ | ||
"name": "your-project", | ||
"name": "Ups", | ||
"version": "1.0.0", | ||
"main": "index.js", | ||
"license": "", | ||
"description": "Localized curation contract for Antelope blockchains", | ||
"main": "ups.hpp", | ||
"contributors": [{ | ||
"name": "Douglas Butner", | ||
"email": "[email protected]", | ||
}], | ||
"license": "MIT", | ||
"scripts": { | ||
"build": "npx fuckyea build", | ||
"deploy": "npx fuckyea deploy", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters