Skip to content

Commit 1071f94

Browse files
authored
fix: release light program test v0.13.1 (#1827)
* fix: alway pick light_system_program_pinocchio.so * chore: adapt cli
1 parent 113381f commit 1071f94

File tree

6 files changed

+26
-58
lines changed

6 files changed

+26
-58
lines changed

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ light-registry = { path = "programs/registry", version = "2.0.0", features = [
184184
create-address-test-program = { path = "program-tests/create-address-test-program", version = "1.0.0", features = [
185185
"cpi",
186186
] }
187-
light-program-test = { path = "sdk-libs/program-test", version = "0.13.0" }
187+
light-program-test = { path = "sdk-libs/program-test", version = "0.13.1" }
188188
light-batched-merkle-tree = { path = "program-libs/batched-merkle-tree", version = "0.3.0" }
189189
light-merkle-tree-metadata = { path = "program-libs/merkle-tree-metadata", version = "0.3.0" }
190190
aligned-sized = { path = "program-libs/aligned-sized", version = "1.1.0" }

cli/src/commands/init/index.ts

Lines changed: 4 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -10,24 +10,20 @@ import { downloadBinIfNotExists } from "../../psp-utils";
1010
import {
1111
PROGRAM_ID,
1212
ANCHOR_VERSION,
13-
BORSH_VERSION,
1413
LIGHT_HASHER_VERSION,
1514
LIGHT_MACROS_VERSION,
1615
LIGHT_SDK_VERSION,
1716
LIGHT_SDK_MACROS_VERSION,
18-
LIGHT_UTILS_VERSION,
19-
LIGHT_VERIFIER_VERSION,
2017
SOLANA_SDK_VERSION,
2118
LIGHT_CLIENT_VERSION,
22-
LIGHT_TEST_UTILS_VERSION,
23-
SOLANA_PROGRAM_TEST_VERSION,
2419
TOKIO_VERSION,
2520
COMPRESSED_PROGRAM_TEMPLATE_TAG,
2621
LIGHT_COMPRESSED_ACCOUNT_VERSION,
27-
LIGHT_ACCOUNT_CHECKS,
2822
STATELESS_JS_VERSION,
2923
LIGHT_CLI_VERSION,
3024
SOLANA_CLI_VERSION,
25+
LIGHT_SDK_TYPES_VERSION,
26+
LIGHT_PROGRAM_TEST_VERSION,
3127
} from "../../utils/constants";
3228
import {
3329
CARGO_GENERATE_TAG,
@@ -97,33 +93,21 @@ export const initRepo = async (name: string, flags: any) => {
9793
"--define",
9894
`anchor-version=${ANCHOR_VERSION}`,
9995
"--define",
100-
`borsh-version=${BORSH_VERSION}`,
101-
"--define",
10296
`light-hasher-version=${LIGHT_HASHER_VERSION}`,
10397
"--define",
10498
`light-macros-version=${LIGHT_MACROS_VERSION}`,
10599
"--define",
106-
`light-account-checks-version=${LIGHT_ACCOUNT_CHECKS}`,
100+
`light-sdk-types-version=${LIGHT_SDK_TYPES_VERSION}`,
107101
"--define",
108102
`light-sdk-version=${LIGHT_SDK_VERSION}`,
109103
"--define",
110104
`light-sdk-macros-version=${LIGHT_SDK_MACROS_VERSION}`,
111105
"--define",
112-
`light-utils-version=${LIGHT_UTILS_VERSION}`,
113-
"--define",
114-
`light-compressed-account-version=${LIGHT_COMPRESSED_ACCOUNT_VERSION}`,
115-
"--define",
116-
`light-verifier-version=${LIGHT_VERIFIER_VERSION}`, // TODO: remove
117-
"--define",
118106
`solana-sdk-version=${SOLANA_SDK_VERSION}`,
119107
"--define",
120108
`light-client-version=${LIGHT_CLIENT_VERSION}`,
121109
"--define",
122-
`light-test-utils-version=${LIGHT_TEST_UTILS_VERSION}`,
123-
"--define",
124-
`light-program-test-version=${SOLANA_PROGRAM_TEST_VERSION}`,
125-
"--define",
126-
`solana-program-test-version=${SOLANA_PROGRAM_TEST_VERSION}`, // TODO: remove
110+
`light-program-test-version=${LIGHT_PROGRAM_TEST_VERSION}`, // TODO: remove
127111
"--define",
128112
`tokio-version=${TOKIO_VERSION}`,
129113
"--define",

cli/src/utils/constants.ts

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -27,22 +27,17 @@ export const BASE_PATH = "../../bin/";
2727
export const PROGRAM_ID = "Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS";
2828
export const SOLANA_SDK_VERSION = "2.2";
2929
export const ANCHOR_VERSION = "0.31.1";
30-
export const BORSH_VERSION = "0.10.4";
31-
export const COMPRESSED_PROGRAM_TEMPLATE_TAG = "v0.3.0";
30+
export const COMPRESSED_PROGRAM_TEMPLATE_TAG = "v0.3.1";
3231
export const TOKIO_VERSION = "1.36.0";
33-
export const SOLANA_PROGRAM_TEST_VERSION = "2.2";
34-
export const LIGHT_CLI_VERSION = "0.25.0";
32+
export const LIGHT_CLI_VERSION = "0.26.0";
3533
export const SOLANA_CLI_VERSION = "2.2.15";
3634

3735
export const LIGHT_HASHER_VERSION = "3.1.0";
3836
export const LIGHT_MACROS_VERSION = "2.1.0";
39-
export const LIGHT_SDK_VERSION = "0.13.0";
4037
export const LIGHT_SDK_MACROS_VERSION = "0.13.0";
41-
export const LIGHT_UTILS_VERSION = "0.13.0";
38+
export const LIGHT_SDK_VERSION = "0.13.0";
39+
export const LIGHT_SDK_TYPES_VERSION = "0.13.0";
4240
export const LIGHT_COMPRESSED_ACCOUNT_VERSION = "0.3.0";
43-
export const LIGHT_VERIFIER_VERSION = "2.0.0";
44-
export const LIGHT_CLIENT_VERSION = "0.9.1";
45-
// TODO: replace with light program test
46-
export const LIGHT_TEST_UTILS_VERSION = "1.2.1";
47-
export const LIGHT_ACCOUNT_CHECKS = "0.3.0";
48-
export const STATELESS_JS_VERSION = "0.21.0";
41+
export const LIGHT_PROGRAM_TEST_VERSION = "0.13.1";
42+
export const LIGHT_CLIENT_VERSION = "0.13.0";
43+
export const STATELESS_JS_VERSION = "0.22.0";

sdk-libs/program-test/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "light-program-test"
3-
version = "0.13.0"
3+
version = "0.13.1"
44
description = "A fast local test environment for Solana programs using compressed accounts and tokens."
55
license = "MIT"
66
edition = "2021"

sdk-libs/program-test/src/utils/setup_light_programs.rs

Lines changed: 12 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -68,30 +68,19 @@ pub fn setup_light_programs(
6868
.inspect_err(|_| {
6969
println!("Program spl_noop bin not found in {}", path);
7070
})?;
71-
#[cfg(feature = "devenv")]
72-
{
73-
let path = format!("{}/light_system_program_pinocchio.so", light_bin_path);
74-
program_test
75-
.add_program_from_file(
76-
light_sdk::constants::LIGHT_SYSTEM_PROGRAM_ID.into(),
77-
path.clone(),
78-
)
79-
.inspect_err(|_| {
80-
println!(
81-
"Program light_system_program_pinocchio bin not found in {}",
82-
path
83-
);
84-
})?;
85-
}
8671

87-
#[cfg(not(feature = "devenv"))]
88-
{
89-
let path = format!("{}/light_system_program.so", light_bin_path);
90-
program_test.add_program_from_file(
91-
Pubkey::from(light_sdk::constants::LIGHT_SYSTEM_PROGRAM_ID),
92-
path,
93-
)?;
94-
}
72+
let path = format!("{}/light_system_program_pinocchio.so", light_bin_path);
73+
program_test
74+
.add_program_from_file(
75+
light_sdk::constants::LIGHT_SYSTEM_PROGRAM_ID.into(),
76+
path.clone(),
77+
)
78+
.inspect_err(|_| {
79+
println!(
80+
"Program light_system_program_pinocchio bin not found in {}",
81+
path
82+
);
83+
})?;
9584

9685
let registered_program = registered_program_test_account_system_program();
9786
program_test

0 commit comments

Comments
 (0)