aboutsummaryrefslogtreecommitdiffstats
path: root/test.js
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2018-03-20 03:46:13 +0000
committerAdam Soltys <[email protected]>2018-03-20 03:46:37 +0000
commit3393eee9498fea178441f2d4783a5285914766ca (patch)
tree09841b75e6a2f71e15868242d26c0781a11bbd86 /test.js
parent84485d68ce6b881eb251d3714addb6da65324a7a (diff)
downloadcoinos-server-3393eee9498fea178441f2d4783a5285914766ca.tar.gz
coinos-server-3393eee9498fea178441f2d4783a5285914766ca.zip
changes for prod
Diffstat (limited to 'test.js')
-rw-r--r--test.js19
1 files changed, 19 insertions, 0 deletions
diff --git a/test.js b/test.js
new file mode 100644
index 00000000..857c5775
--- /dev/null
+++ b/test.js
@@ -0,0 +1,19 @@
+import fs from 'fs'
+import grpc from 'grpc'
+
+try {
+ ;(async () => {
+ const lna = await require('lnrpc')({ server: 'localhost:10001', tls: '/home/adam/.lnd/tls.cert' })
+ const maca = fs.readFileSync('/home/adam/.lnd/test.macaroon')
+ const meta = new grpc.Metadata()
+ meta.add('macaroon', maca.toString('hex'))
+ lna.meta = meta
+ console.log('meow')
+ try {
+ let i = await lna.getInfo({}, meta)
+ console.log('i', i)
+ } catch (e) { console.log(e) }
+ })()
+} catch (e) { console.log(e) }
+
+console.log('done')