Skip to content

Commit 10dce76

Browse files
committed
address comments
1 parent efd6e52 commit 10dce76

File tree

2 files changed

+1
-11
lines changed

2 files changed

+1
-11
lines changed

program/rust/src/tests/pyth_simulator.rs

-10
Original file line numberDiff line numberDiff line change
@@ -102,16 +102,6 @@ struct ProductMetadata {
102102
impl PythSimulator {
103103
/// Deploys the oracle program as upgradable
104104
pub async fn new() -> PythSimulator {
105-
let mut cmd = std::process::Command::new("cargo");
106-
cmd.arg("build-bpf");
107-
let status = cmd.status().unwrap();
108-
109-
if !status.success() {
110-
panic!(
111-
"cargo-build-bpf did not exit with 0 (code {:?})",
112-
status.code()
113-
);
114-
}
115105
let target_dir = concat!(env!("CARGO_MANIFEST_DIR"), "/../../target");
116106
let oracle_program_binary_path = PathBuf::from(target_dir).join("deploy/pyth_oracle.so");
117107
let mut bpf_data = read_file(&oracle_program_binary_path);

scripts/build-bpf.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ set -x
2020
cd "${PYTH_DIR}"
2121

2222
# Re-run tests affected by features
23-
cargo test --locked
23+
cargo-test-bpf
2424

2525
cargo-build-bpf -- --locked -Z build-std=std,panic_abort -Z build-std-features=panic_immediate_abort
2626
sha256sum ./target/**/*.so

0 commit comments

Comments
 (0)