From ef7c46d1241347abdae7ee21e0e498fe34a1ecd3 Mon Sep 17 00:00:00 2001 From: ksolana <110843012+ksolana@users.noreply.github.com> Date: Wed, 15 May 2024 22:51:53 -0700 Subject: [PATCH 1/2] Fix program keypair file and add assertions to verify program output --- basics/hello-solana/native/package.json | 2 +- basics/hello-solana/native/tests/test.ts | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/basics/hello-solana/native/package.json b/basics/hello-solana/native/package.json index 6de220221..e772d7dca 100644 --- a/basics/hello-solana/native/package.json +++ b/basics/hello-solana/native/package.json @@ -3,7 +3,7 @@ "test": "pnpm ts-mocha -p ./tsconfig.json -t 1000000 ./tests/test.ts", "build-and-test": "cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./tests/fixtures && pnpm test", "build": "cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so", - "deploy": "solana program deploy ./program/target/so/program.so" + "deploy": "solana program deploy ./program/target/so/hello_solana_program.so" }, "dependencies": { "@solana/web3.js": "^1.47.3" diff --git a/basics/hello-solana/native/tests/test.ts b/basics/hello-solana/native/tests/test.ts index 8a1bba278..ce5523181 100644 --- a/basics/hello-solana/native/tests/test.ts +++ b/basics/hello-solana/native/tests/test.ts @@ -1,3 +1,4 @@ +asdfasdg import { PublicKey, Transaction, @@ -27,6 +28,7 @@ describe('hello-solana', async () => { tx.add(ix).sign(payer); // Now we process the transaction - await client.processTransaction(tx); + let transaction = await client.processTransaction(tx); + console.log(transaction?.meta?.logMessages); }); }); From e6205c930fb05093f8cc6033f441c8ff884417bb Mon Sep 17 00:00:00 2001 From: Jacob Creech <82475023+jacobcreech@users.noreply.github.com> Date: Fri, 17 May 2024 13:26:01 -0500 Subject: [PATCH 2/2] Update basics/hello-solana/native/tests/test.ts --- basics/hello-solana/native/tests/test.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/basics/hello-solana/native/tests/test.ts b/basics/hello-solana/native/tests/test.ts index ce5523181..06fd9d6f8 100644 --- a/basics/hello-solana/native/tests/test.ts +++ b/basics/hello-solana/native/tests/test.ts @@ -1,4 +1,3 @@ -asdfasdg import { PublicKey, Transaction,