Socket
Socket
Sign inDemoInstall

hh-test-lib

Package Overview
Dependencies
201
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.1.1 to 0.1.2

25

artifacts/testLib.json
{
"version": 9,
"compilerVersion": "1.19.0+commit.72eaeba",
"contract": "TestLibContract",
"md5": "f07eb01282ca9843f0e688e54110c199",
"contract": "TestLib",
"md5": "b802607f3256e11911d7688553ce5599",
"structs": [],

@@ -28,5 +28,3 @@ "library": [

{
"type": "function",
"name": "unlock1",
"index": 0,
"type": "constructor",
"params": [

@@ -38,17 +36,2 @@ {

]
},
{
"type": "function",
"name": "unlock2",
"index": 1,
"params": [
{
"name": "x",
"type": "int"
}
]
},
{
"type": "constructor",
"params": []
}

@@ -59,4 +42,4 @@ ],

"file": "file:///C:/Users/myland/code/test-lib/artifacts/testLib.scrypt",
"hex": "00790087635152615179517993517a75517a756152799c777767007951876355616152615179517994517a756153799c77777767006868",
"hex": "<x>",
"sourceMapFile": ""
}

@@ -1,2 +0,2 @@

import { SmartContractLib, SmartContract } from 'scrypt-ts';
import { SmartContractLib } from 'scrypt-ts';
export declare class TestLib extends SmartContractLib {

@@ -8,5 +8,1 @@ x: bigint;

}
export declare class TestLibContract extends SmartContract {
unlock1(x: bigint): void;
unlock2(x: bigint): void;
}

@@ -9,3 +9,3 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
exports.TestLibContract = exports.TestLib = void 0;
exports.TestLib = void 0;
const scrypt_ts_1 = require("scrypt-ts");

@@ -34,19 +34,2 @@ class TestLib extends scrypt_ts_1.SmartContractLib {

], TestLib, "add", null);
// Test via smart contract:
class TestLibContract extends scrypt_ts_1.SmartContract {
unlock1(x) {
(0, scrypt_ts_1.assert)(TestLib.add(1n, 2n) === x);
}
unlock2(x) {
const myLib = new TestLib(5n);
(0, scrypt_ts_1.assert)(myLib.diff(2n) === x);
}
}
exports.TestLibContract = TestLibContract;
__decorate([
(0, scrypt_ts_1.method)()
], TestLibContract.prototype, "unlock1", null);
__decorate([
(0, scrypt_ts_1.method)()
], TestLibContract.prototype, "unlock2", null);
//# sourceMappingURL=testLib.js.map

2

package.json
{
"name": "hh-test-lib",
"version": "0.1.1",
"version": "0.1.2",
"description": "A demo sCrypt library.",

@@ -5,0 +5,0 @@ "author": "",

@@ -1,1 +0,1 @@

{"scryptBase":"artifacts","bindings":[{"symbol":"TestLib","path":"testLib.scrypt"},{"symbol":"TestLibContract","path":"testLib.scrypt"}]}
{"scryptBase":"artifacts","bindings":[{"symbol":"TestLib","path":"testLib.scrypt"}]}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc