Skip to content

Commit

Permalink
initial
Browse files Browse the repository at this point in the history
  • Loading branch information
Connoropolous committed Nov 20, 2018
1 parent 7d2c58c commit 8146c52
Show file tree
Hide file tree
Showing 11 changed files with 1,657 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
dist/
node_modules/
target/

4 changes: 4 additions & 0 deletions .hcignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
dist
test
bundle.json
README.md
14 changes: 14 additions & 0 deletions app.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"name": "Holochain App Name",
"description": "A Holochain app",
"authors": [
{
"indentifier": "Author Name <[email protected]>",
"public_key_source": "",
"signature": ""
}
],
"version": "0.1.0",
"dht": {},
"properties": null
}
16 changes: 16 additions & 0 deletions test/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
// This test file uses the tape testing framework.
// To learn more, go here: https://github.com/substack/tape
const test = require('tape');
const Container = require('@holochain/holochain-nodejs');

// instantiate an app from the DNA JSON bundle
const app = Container.loadAndInstantiate("dist/bundle.json")

// activate the new instance
app.start()

test('commit', (t) => {
const result = app.call("people", "main", "hash_post", JSON.stringify({ content: "test" }))
t.equal(JSON.parse(result), "QmaErP4TAA7C39JfDFqzq3R57GnhevtoVC7H5eWK9r8hWU")
t.end()
})
Loading

0 comments on commit 8146c52

Please sign in to comment.