diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 709966cf37..c544a9286f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -79,8 +79,8 @@ jobs: "examples/basic_bitcoin", "examples/bitcoin", "examples/bitcoin_psbt", - "examples/bitcoinjs-lib", - "examples/bitcore-lib", + "examples/bitcoinjs_lib", + "examples/bitcore_lib", "examples/blob_array", "examples/bytes", "examples/call_raw", diff --git a/examples/bitcoinjs-lib/.gitignore b/examples/bitcoinjs_lib/.gitignore similarity index 100% rename from examples/bitcoinjs-lib/.gitignore rename to examples/bitcoinjs_lib/.gitignore diff --git a/examples/bitcoinjs-lib/LICENCE b/examples/bitcoinjs_lib/LICENCE similarity index 100% rename from examples/bitcoinjs-lib/LICENCE rename to examples/bitcoinjs_lib/LICENCE diff --git a/examples/bitcoinjs-lib/dfx.json b/examples/bitcoinjs_lib/dfx.json similarity index 100% rename from examples/bitcoinjs-lib/dfx.json rename to examples/bitcoinjs_lib/dfx.json diff --git a/examples/bitcoinjs-lib/package-lock.json b/examples/bitcoinjs_lib/package-lock.json similarity index 99% rename from examples/bitcoinjs-lib/package-lock.json rename to examples/bitcoinjs_lib/package-lock.json index 305117bbff..c838c60934 100644 --- a/examples/bitcoinjs-lib/package-lock.json +++ b/examples/bitcoinjs_lib/package-lock.json @@ -1,5 +1,5 @@ { - "name": "bitcoinjs-lib", + "name": "bitcoinjs_lib", "lockfileVersion": 2, "requires": true, "packages": { @@ -9,7 +9,7 @@ "azle": "0.21.1", "bitcoinjs-lib": "^6.1.5", "bitcoinjs-message": "^2.2.0", - "bitcore-lib-example": "file:../bitcore-lib", + "bitcore_lib_example": "file:../bitcore_lib", "ecpair": "^2.1.0", "express": "^4.18.2", "tiny-secp256k1": "^2.2.3" @@ -20,8 +20,22 @@ "typescript": "^5.2.2" } }, + "../bitcore_lib": { + "dependencies": { + "azle": "0.21.1", + "bitcore-lib": "^10.0.23", + "express": "^4.18.2" + }, + "devDependencies": { + "@types/bitcore-lib": "^0.15.6", + "@types/express": "^4.17.21", + "ts-node": "^10.9.1", + "typescript": "^5.2.2" + } + }, "../bitcore-lib": { "name": "bitcore-lib-example", + "extraneous": true, "dependencies": { "azle": "0.21.1", "bitcore-lib": "^10.0.23", @@ -1199,8 +1213,8 @@ "safe-buffer": "^5.1.2" } }, - "node_modules/bitcore-lib-example": { - "resolved": "../bitcore-lib", + "node_modules/bitcore_lib_example": { + "resolved": "../bitcore_lib", "link": true }, "node_modules/bn.js": { @@ -3801,8 +3815,8 @@ } } }, - "bitcore-lib-example": { - "version": "file:../bitcore-lib", + "bitcore_lib_example": { + "version": "file:../bitcore_lib", "requires": { "@types/bitcore-lib": "^0.15.6", "@types/express": "^4.17.21", diff --git a/examples/bitcoinjs-lib/package.json b/examples/bitcoinjs_lib/package.json similarity index 91% rename from examples/bitcoinjs-lib/package.json rename to examples/bitcoinjs_lib/package.json index eaf5a56835..86b1c67054 100644 --- a/examples/bitcoinjs-lib/package.json +++ b/examples/bitcoinjs_lib/package.json @@ -8,7 +8,7 @@ "azle": "0.21.1", "bitcoinjs-lib": "^6.1.5", "bitcoinjs-message": "^2.2.0", - "bitcore-lib-example": "file:../bitcore-lib", + "bitcore_lib_example": "file:../bitcore_lib", "ecpair": "^2.1.0", "express": "^4.18.2", "tiny-secp256k1": "^2.2.3" diff --git a/examples/bitcoinjs-lib/src/index.ts b/examples/bitcoinjs_lib/src/index.ts similarity index 100% rename from examples/bitcoinjs-lib/src/index.ts rename to examples/bitcoinjs_lib/src/index.ts diff --git a/examples/bitcoinjs-lib/test/pretest.ts b/examples/bitcoinjs_lib/test/pretest.ts similarity index 100% rename from examples/bitcoinjs-lib/test/pretest.ts rename to examples/bitcoinjs_lib/test/pretest.ts diff --git a/examples/bitcoinjs-lib/test/test.ts b/examples/bitcoinjs_lib/test/test.ts similarity index 100% rename from examples/bitcoinjs-lib/test/test.ts rename to examples/bitcoinjs_lib/test/test.ts diff --git a/examples/bitcoinjs-lib/test/tests.ts b/examples/bitcoinjs_lib/test/tests.ts similarity index 98% rename from examples/bitcoinjs-lib/test/tests.ts rename to examples/bitcoinjs_lib/test/tests.ts index c13fe1e14c..cbb79acdac 100644 --- a/examples/bitcoinjs-lib/test/tests.ts +++ b/examples/bitcoinjs_lib/test/tests.ts @@ -2,7 +2,7 @@ import * as dns from 'node:dns'; dns.setDefaultResultOrder('ipv4first'); import { Test } from 'azle/test'; -import { getTests as getBitcoinTests } from 'bitcore-lib-example/test/tests'; +import { getTests as getBitcoinTests } from 'bitcore_lib_example/test/tests'; export function getTests(canisterId: string): Test[] { const origin = `http://${canisterId}.localhost:8000`; diff --git a/examples/bitcoinjs-lib/tsconfig.json b/examples/bitcoinjs_lib/tsconfig.json similarity index 100% rename from examples/bitcoinjs-lib/tsconfig.json rename to examples/bitcoinjs_lib/tsconfig.json diff --git a/examples/bitcore-lib/.gitignore b/examples/bitcore_lib/.gitignore similarity index 100% rename from examples/bitcore-lib/.gitignore rename to examples/bitcore_lib/.gitignore diff --git a/examples/bitcore-lib/LICENCE b/examples/bitcore_lib/LICENCE similarity index 100% rename from examples/bitcore-lib/LICENCE rename to examples/bitcore_lib/LICENCE diff --git a/examples/bitcore-lib/dfx.json b/examples/bitcore_lib/dfx.json similarity index 100% rename from examples/bitcore-lib/dfx.json rename to examples/bitcore_lib/dfx.json diff --git a/examples/bitcore-lib/package-lock.json b/examples/bitcore_lib/package-lock.json similarity index 99% rename from examples/bitcore-lib/package-lock.json rename to examples/bitcore_lib/package-lock.json index 268428cc10..c21463baa8 100644 --- a/examples/bitcore-lib/package-lock.json +++ b/examples/bitcore_lib/package-lock.json @@ -1,10 +1,10 @@ { - "name": "bitcore-lib-example", + "name": "bitcore_lib_example", "lockfileVersion": 2, "requires": true, "packages": { "": { - "name": "bitcore-lib-example", + "name": "bitcore_lib_example", "dependencies": { "azle": "0.21.1", "bitcore-lib": "^10.0.23", diff --git a/examples/bitcore-lib/package.json b/examples/bitcore_lib/package.json similarity index 93% rename from examples/bitcore-lib/package.json rename to examples/bitcore_lib/package.json index e26ab957bf..f21b930652 100644 --- a/examples/bitcore-lib/package.json +++ b/examples/bitcore_lib/package.json @@ -1,5 +1,5 @@ { - "name": "bitcore-lib-example", + "name": "bitcore_lib_example", "scripts": { "pretest": "ts-node --transpile-only --ignore=false test/pretest.ts", "test": "ts-node --transpile-only --ignore=false test/test.ts" diff --git a/examples/bitcore-lib/src/index.ts b/examples/bitcore_lib/src/index.ts similarity index 100% rename from examples/bitcore-lib/src/index.ts rename to examples/bitcore_lib/src/index.ts diff --git a/examples/bitcore-lib/test/pretest.ts b/examples/bitcore_lib/test/pretest.ts similarity index 100% rename from examples/bitcore-lib/test/pretest.ts rename to examples/bitcore_lib/test/pretest.ts diff --git a/examples/bitcore-lib/test/test.ts b/examples/bitcore_lib/test/test.ts similarity index 100% rename from examples/bitcore-lib/test/test.ts rename to examples/bitcore_lib/test/test.ts diff --git a/examples/bitcore-lib/test/tests.ts b/examples/bitcore_lib/test/tests.ts similarity index 98% rename from examples/bitcore-lib/test/tests.ts rename to examples/bitcore_lib/test/tests.ts index abc6c3d1f9..d4a9499511 100644 --- a/examples/bitcore-lib/test/tests.ts +++ b/examples/bitcore_lib/test/tests.ts @@ -1,3 +1,6 @@ +import * as dns from 'node:dns'; +dns.setDefaultResultOrder('ipv4first'); + import { Test } from 'azle/test'; export function getTests(canisterId: string): Test[] { diff --git a/examples/bitcore-lib/tsconfig.json b/examples/bitcore_lib/tsconfig.json similarity index 100% rename from examples/bitcore-lib/tsconfig.json rename to examples/bitcore_lib/tsconfig.json