Skip to content

Add tests#61

Draft
MakisChristou wants to merge 1 commit into
mainfrom
makis/tx_call_tests
Draft

Add tests#61
MakisChristou wants to merge 1 commit into
mainfrom
makis/tx_call_tests

Conversation

@MakisChristou

@MakisChristou MakisChristou commented Dec 16, 2024

Copy link
Copy Markdown
Contributor

This pr is for covering the new functionality added in Thor

@socket-security

Copy link
Copy Markdown

New and removed dependencies detected. Learn more about Socket for GitHub ↗︎

Package New capabilities Transitives Size Publisher
npm/@eslint/js@9.17.0 None 0 14.9 kB eslintbot, openjsfoundation
npm/@jridgewell/gen-mapping@0.3.8 None 0 0 B
npm/antlr4ts@0.5.0-alpha.4 None 0 3.02 MB sharwell
npm/browserslist@4.24.3 None 0 0 B
npm/call-bound@1.0.3 None 0 12 kB ljharb
npm/caniuse-lite@1.0.30001689 None 0 2.15 MB ai, beneb, caniuse-lite
npm/electron-to-chromium@1.5.73 None 0 0 B
npm/es-object-atoms@1.0.0 None 0 9.17 kB ljharb
npm/eslint@9.17.0 Transitive: eval, filesystem +3 4.32 MB eslintbot, openjsfoundation
npm/get-intrinsic@1.2.6 eval +2 78.7 kB ljharb
npm/is-arguments@1.2.0 None 0 32.7 kB ljharb
npm/is-core-module@2.16.0 None 0 33.2 kB ljharb
npm/jsesc@3.1.0 None 0 32.3 kB mathias
npm/math-intrinsics@1.0.0 None 0 16.5 kB ljharb
npm/resolve@1.22.9 None 0 3.09 MB ljharb
npm/side-channel-list@1.0.0 None 0 14.7 kB ljharb
npm/side-channel-map@1.0.1 None 0 13.3 kB ljharb
npm/side-channel-weakmap@1.0.2 None 0 14.7 kB ljharb
npm/side-channel@1.1.0 None 0 21.5 kB ljharb
npm/viem@2.21.55 network 0 13.9 MB jmoxey
npm/zod@3.24.1 None 0 0 B

🚮 Removed packages: npm/@eslint/js@9.16.0, npm/@isaacs/cliui@8.0.2, npm/@isaacs/fs-minipass@4.0.1, npm/@jridgewell/gen-mapping@0.3.5, npm/@npmcli/agent@3.0.0, npm/@npmcli/fs@4.0.0, npm/@pkgjs/parseargs@0.11.0, npm/abbrev@2.0.0, npm/ansi-regex@6.1.0, npm/antlr4ts@0.5.0-dev, npm/browserslist@4.24.2, npm/cacache@19.0.1, npm/caniuse-lite@1.0.30001687, npm/chownr@3.0.0, npm/eastasianwidth@0.2.0, npm/electron-to-chromium@1.5.72, npm/emoji-regex@9.2.2, npm/encoding@0.1.13, npm/err-code@2.0.3, npm/eslint@9.16.0, npm/exponential-backoff@3.1.1, npm/foreground-child@3.3.0, npm/fs-minipass@3.0.3, npm/get-intrinsic@1.2.5, npm/glob@10.4.5, npm/http-cache-semantics@4.1.1, npm/http-proxy-agent@7.0.2, npm/iconv-lite@0.6.3, npm/ip-address@9.0.5, npm/is-arguments@1.1.1, npm/is-core-module@2.15.1, npm/isexe@3.1.1, npm/jackspeak@3.4.3, npm/jsbn@1.1.0, npm/make-fetch-happen@14.0.3, npm/minipass-collect@2.0.1, npm/minipass-fetch@4.0.0, npm/minipass-flush@1.0.5, npm/minipass-pipeline@1.2.4, npm/minipass-sized@1.0.3, npm/minizlib@3.0.1, npm/mkdirp@3.0.1, npm/negotiator@1.0.0, npm/node-gyp@11.0.0, npm/nopt@8.0.0, npm/p-map@7.0.3, npm/package-json-from-dist@1.0.1, npm/path-scurry@1.11.1, npm/proc-log@5.0.0, npm/promise-retry@2.0.1, npm/resolve@1.22.8, npm/rimraf@5.0.10, npm/side-channel@1.0.6, npm/signal-exit@4.1.0, npm/smart-buffer@4.2.0, npm/socks-proxy-agent@8.0.5, npm/socks@2.8.3, npm/sprintf-js@1.1.3, npm/ssri@12.0.0, npm/string-width-cjs@4.2.3, npm/string-width@5.1.2, npm/strip-ansi-cjs@6.0.1, npm/strip-ansi@7.1.0, npm/tar@7.4.3, npm/unique-filename@4.0.0, npm/unique-slug@5.0.0, npm/viem@2.21.54, npm/which@5.0.0, npm/wrap-ansi-cjs@7.0.0, npm/wrap-ansi@8.1.0, npm/zod@3.24.0

View full report↗︎

Comment thread .env
PRIVATE_KEYS=
MNEMONIC="denial kitchen pet squirrel other broom bar gas better priority spoil cross"
NETWORK_TYPE=default-private
NETWORK_TYPE=solo

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suppose we dont need to push this one, as it is just local config

Comment thread src/wallet.js
}
}

buildCallTransaction = async (clauses, options) => {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need to have specific method for that or we can enhance buildTransaction one ?

expect(success).toBeTrue()
expect(httpCode).toBe(200)
expect(body?.txID).toBeDefined()
expect(body?.vmError).not.toBe("")

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wonder if we can add specific error we look for ? as this just checks it is not empty

)
})

it.e2eTest('should simulate vet transfer', 'all', async function () {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe we can add: mixed clauses (like contract call + vet transfer), tx delegation and not enough gas cases. As this should follow the same validation rules

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants