-
Notifications
You must be signed in to change notification settings - Fork 76
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
All tests that are being removed are now duplicates of tests that are in stellar-sdk. So are the test-custom-types tests, but those ones actually caught some edge cases, so maybe they're worth keeping.
- Loading branch information
Showing
7 changed files
with
8 additions
and
244 deletions.
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
cmd/crates/soroban-spec-typescript/fixtures/test_custom_types/package-lock.json
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 5 additions & 7 deletions
12
cmd/crates/soroban-spec-typescript/ts-tests/src/test-deserialized-transaction.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,20 @@ | ||
import test from "ava" | ||
import { rpcUrl, root, signer } from "./util.js" | ||
import { Client, networks } from "test-hello-world" | ||
import { Client, networks } from "test-custom-types" | ||
|
||
const contract = new Client({ | ||
...networks.standalone, | ||
rpcUrl, | ||
allowHttp: true, | ||
publicKey: root.keypair.publicKey(), | ||
...signer, | ||
...networks.standalone, | ||
}) | ||
|
||
test("has correctly-typed result", async (t) => { | ||
const initial = await contract.hello({ world: "tests" }) | ||
t.is(initial.result[0], "Hello") | ||
t.is(initial.result[1], "tests") | ||
const initial = await contract.hello({ hello: "tests" }) | ||
t.is(initial.result, "tests") | ||
|
||
const serialized = initial.toJSON() | ||
const deserialized = contract.fromJSON.hello(serialized) | ||
t.is(deserialized.result[0], "Hello") // throws TS error if `result` is of type `unknown` | ||
t.is(deserialized.result[1], "tests") // throws TS error if `result` is of type `unknown` | ||
t.is(deserialized.result, "tests") // throws TS error if `result` is of type `unknown` | ||
}); |
32 changes: 0 additions & 32 deletions
32
cmd/crates/soroban-spec-typescript/ts-tests/src/test-hello-world.ts
This file was deleted.
Oops, something went wrong.
18 changes: 0 additions & 18 deletions
18
cmd/crates/soroban-spec-typescript/ts-tests/src/test-methods-as-args.ts
This file was deleted.
Oops, something went wrong.
140 changes: 0 additions & 140 deletions
140
cmd/crates/soroban-spec-typescript/ts-tests/src/test-swap.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters