Skip to content

Commit

Permalink
Merge pull request #12 from joncinque/test-validator
Browse files Browse the repository at this point in the history
Add localnet using solana-test-validator
  • Loading branch information
joncinque authored May 7, 2021
2 parents 427d494 + 16e8180 commit f5b1705
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,5 @@ yarn-debug.log*
yarn-error.log*

.idea

/test-ledger
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,10 @@
"build": "craco build",
"test": "craco test",
"eject": "react-scripts eject",
"localnet:update": "solana-localnet update",
"localnet:up": "rm client/util/store/config.json; set -x; solana-localnet down; set -e; solana-localnet up",
"localnet:down": "solana-localnet down",
"localnet:logs": "solana-localnet logs -f",
"program:build": "cd program && cargo build-bpf",
"program:test": "cd program && cargo test-bpf",
"localnet:up": "solana-test-validator --bpf-program BpfProgram1111111111111111111111111111111111 program/target/deploy/bpf_program_template.so --reset",
"localnet:logs": "solana logs",
"predeploy": "git pull --ff-only && yarn && yarn build",
"deploy": "gh-pages -d build",
"deploy:ar": "arweave deploy-dir build --key-file ",
Expand Down
2 changes: 2 additions & 0 deletions program/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ use solana_program::{
account_info::AccountInfo, entrypoint, entrypoint::ProgramResult, msg, pubkey::Pubkey,
};

solana_program::declare_id!("BpfProgram1111111111111111111111111111111111");

entrypoint!(process_instruction);
fn process_instruction(
program_id: &Pubkey,
Expand Down

0 comments on commit f5b1705

Please sign in to comment.