Skip to content

Commit 499eb7e

Browse files
committed
Disable scarb 2.10.0 specific tests
commit-id:3ae67c8b
1 parent 049d762 commit 499eb7e

File tree

7 files changed

+18
-67
lines changed

7 files changed

+18
-67
lines changed

.github/workflows/ci.yml

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -44,14 +44,6 @@ jobs:
4444
- uses: software-mansion/setup-scarb@v1
4545
- uses: software-mansion/setup-universal-sierra-compiler@v1
4646
- run: cargo test --release --lib -p forge
47-
# TODO(#3096): Remove running tests with `scarb_since_2_10`
48-
- uses: software-mansion/setup-scarb@v1
49-
with:
50-
scarb-version: "2.10.1"
51-
- name: Check and lint forge templates
52-
run: cargo test --release -p forge --features scarb_since_2_10 validate_templates
53-
- name: Check and lint snforge_std
54-
run: cargo test --release -p forge --features scarb_since_2_10 validate_snforge_std
5547

5648
build-test-forge-nextest-archive:
5749
needs: setup
@@ -166,21 +158,6 @@ jobs:
166158
- run: cargo test --package forge --features scarb_2_9_1 --lib compatibility_check::tests::warning_requirements
167159
- run: cargo test --package forge --features scarb_2_9_1 --test main e2e::running::sierra_gas_with_older_scarb
168160

169-
# todo(3096): Remove this and the feature as soon as scarb 2.10 is the oldest officially supported version
170-
test-scarb-since-2-10:
171-
name: Test scarb 2.10
172-
runs-on: ubuntu-latest
173-
steps:
174-
- uses: actions/checkout@v4
175-
- uses: dtolnay/rust-toolchain@stable
176-
- uses: Swatinem/rust-cache@9d47c6ad4b02e050fd481d890b2ea34778fd09d6
177-
- uses: software-mansion/setup-scarb@v1
178-
with:
179-
scarb-version: "2.10.1"
180-
- uses: software-mansion/setup-universal-sierra-compiler@v1
181-
182-
- run: cargo test --package forge --features scarb_since_2_10 sierra_gas
183-
184161
test-forge-runner:
185162
name: Test Forge Runner
186163
runs-on: ubuntu-latest
@@ -284,12 +261,7 @@ jobs:
284261
- uses: software-mansion/setup-universal-sierra-compiler@v1
285262
- name: Run tests
286263
run: cargo test --release -p sncast
287-
# TODO(#3096): Remove running tests with `scarb_since_2_10`
288-
- uses: software-mansion/setup-scarb@v1
289-
with:
290-
scarb-version: "2.10.1"
291264
- name: Check and lint sncast_std
292-
run: cargo test --release -p sncast --features scarb_since_2_10 validate_sncast_std
293265

294266
test-conversions:
295267
name: Test Conversions

crates/forge/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ edition.workspace = true
88
[features]
99
smoke = []
1010
scarb_2_9_1 = []
11-
scarb_since_2_10 = []
1211
no_scarb_installed = []
1312
debugging = []
1413
assert_non_exact_gas = ["test_utils/assert_non_exact_gas"]

crates/forge/tests/e2e/running.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -861,7 +861,6 @@ fn detailed_resources_flag() {
861861
}
862862

863863
#[test]
864-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
865864
fn detailed_resources_flag_sierra_gas() {
866865
let temp = setup_package("erc20_package");
867866
let output = test_runner(&temp)

crates/forge/tests/integration/gas.rs

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1008,7 +1008,6 @@ fn events_contract_cost_cairo_steps() {
10081008
}
10091009

10101010
#[test]
1011-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
10121011
fn declare_cost_is_omitted_sierra_gas() {
10131012
let test = test_case!(
10141013
indoc!(
@@ -1044,7 +1043,6 @@ fn declare_cost_is_omitted_sierra_gas() {
10441043
}
10451044

10461045
#[test]
1047-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
10481046
fn deploy_syscall_cost_sierra_gas() {
10491047
let test = test_case!(
10501048
indoc!(
@@ -1093,7 +1091,6 @@ fn deploy_syscall_cost_sierra_gas() {
10931091
}
10941092

10951093
#[test]
1096-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
10971094
fn snforge_std_deploy_cost_sierra_gas() {
10981095
let test = test_case!(
10991096
indoc!(
@@ -1134,7 +1131,6 @@ fn snforge_std_deploy_cost_sierra_gas() {
11341131
}
11351132

11361133
#[test]
1137-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
11381134
fn keccak_cost_sierra_gas() {
11391135
let test = test_case!(indoc!(
11401136
r"
@@ -1164,7 +1160,6 @@ fn keccak_cost_sierra_gas() {
11641160
}
11651161

11661162
#[test]
1167-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
11681163
fn contract_keccak_cost_sierra_gas() {
11691164
let test = test_case!(
11701165
indoc!(
@@ -1214,7 +1209,6 @@ fn contract_keccak_cost_sierra_gas() {
12141209
}
12151210

12161211
#[test]
1217-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
12181212
fn contract_range_check_cost_sierra_gas() {
12191213
let test = test_case!(
12201214
indoc!(
@@ -1260,7 +1254,6 @@ fn contract_range_check_cost_sierra_gas() {
12601254
}
12611255

12621256
#[test]
1263-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
12641257
fn storage_write_cost_sierra_gas() {
12651258
let test = test_case!(
12661259
indoc!(
@@ -1312,7 +1305,6 @@ fn storage_write_cost_sierra_gas() {
13121305
}
13131306

13141307
#[test]
1315-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
13161308
fn multiple_storage_writes_cost_sierra_gas() {
13171309
let test = test_case!(
13181310
indoc!(
@@ -1371,7 +1363,6 @@ fn multiple_storage_writes_cost_sierra_gas() {
13711363
}
13721364

13731365
#[test]
1374-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
13751366
fn l1_message_cost_sierra_gas() {
13761367
let test = test_case!(
13771368
indoc!(
@@ -1422,7 +1413,6 @@ fn l1_message_cost_sierra_gas() {
14221413
}
14231414

14241415
#[test]
1425-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
14261416
fn l1_message_cost_for_proxy_sierra_gas() {
14271417
let test = test_case!(
14281418
indoc!(
@@ -1487,7 +1477,6 @@ fn l1_message_cost_for_proxy_sierra_gas() {
14871477
}
14881478

14891479
#[test]
1490-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
14911480
fn events_cost_sierra_gas() {
14921481
let test = test_case!(indoc!(
14931482
r"
@@ -1534,7 +1523,6 @@ fn events_cost_sierra_gas() {
15341523
}
15351524

15361525
#[test]
1537-
#[cfg_attr(not(feature = "scarb_since_2_10"), ignore)]
15381526
fn events_contract_cost_sierra_gas() {
15391527
let test = test_case!(
15401528
indoc!(

crates/sncast/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,6 @@ packages_validation = { path = "../testing/packages_validation" }
7171

7272
[features]
7373
default = []
74-
scarb_since_2_10 = ["packages_validation/scarb_since_2_10"]
7574

7675
[[bin]]
7776
name = "sncast"

crates/testing/packages_validation/Cargo.toml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,3 @@ project-root.workspace = true
1212

1313
[dev-dependencies]
1414
test-case.workspace = true
15-
16-
[features]
17-
scarb_since_2_10 = []

crates/testing/packages_validation/src/lib.rs

Lines changed: 18 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -16,26 +16,23 @@ pub fn check_and_lint(package_path: &Utf8PathBuf) {
1616
"`scarb check` failed in {package_path}",
1717
);
1818

19-
// TODO(#3149)
20-
if cfg!(feature = "scarb_since_2_10") {
21-
let lint_output = ScarbCommand::new()
22-
.current_dir(package_path)
23-
.arg("lint")
24-
.command()
25-
.stdout(Stdio::inherit())
26-
.stderr(Stdio::inherit())
27-
.output()
28-
.expect("Failed to run `scarb lint`");
29-
assert!(
30-
lint_output.status.success(),
31-
"`scarb lint` failed in {package_path}"
32-
);
19+
let lint_output = ScarbCommand::new()
20+
.current_dir(package_path)
21+
.arg("lint")
22+
.command()
23+
.stdout(Stdio::inherit())
24+
.stderr(Stdio::inherit())
25+
.output()
26+
.expect("Failed to run `scarb lint`");
27+
assert!(
28+
lint_output.status.success(),
29+
"`scarb lint` failed in {package_path}"
30+
);
3331

34-
// TODO(#3212): Once out minimal supported scarb version is 2.12.0, we should
35-
// check status instead of checking if stdout is not empty
36-
assert!(
37-
lint_output.stdout.is_empty(),
38-
"`scarb lint` output should be empty"
39-
);
40-
}
32+
// TODO(#3212): Once out minimal supported scarb version is 2.12.0, we should
33+
// check status instead of checking if stdout is not empty
34+
assert!(
35+
lint_output.stdout.is_empty(),
36+
"`scarb lint` output should be empty"
37+
);
4138
}

0 commit comments

Comments
 (0)