mirror of
https://github.com/bevyengine/bevy
synced 2024-11-13 00:17:27 +00:00
fix test and tweak github action
This commit is contained in:
parent
cb81f3a6f0
commit
8a14e61d0f
2 changed files with 14 additions and 7 deletions
2
.github/workflows/rust.yml
vendored
2
.github/workflows/rust.yml
vendored
|
@ -21,5 +21,5 @@ jobs:
|
||||||
- name: Build
|
- name: Build
|
||||||
run: cargo build --verbose
|
run: cargo build --verbose
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: cargo test --verbose --all --no-default-features --features headless
|
run: cargo test --verbose --workspace
|
||||||
|
|
||||||
|
|
|
@ -252,11 +252,18 @@ mod tests {
|
||||||
"a2_b2 batch should have e2 and e3"
|
"a2_b2 batch should have e2 and e3"
|
||||||
);
|
);
|
||||||
|
|
||||||
assert_eq!(
|
let mut found_a1_b1 = false;
|
||||||
batcher
|
let mut found_a2_b2 = false;
|
||||||
.iter()
|
for batch in batcher.iter() {
|
||||||
.collect::<Vec<&Batch<HandleUntyped, Entity, Data>>>(),
|
if batch == &a1_b1_batch {
|
||||||
vec![&a1_b1_batch, &a2_b2_batch]
|
found_a1_b1 = true;
|
||||||
)
|
} else if batch == &a2_b2_batch {
|
||||||
|
found_a2_b2 = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
assert!(found_a1_b1 && found_a2_b2);
|
||||||
|
assert_eq!(batcher.iter().count(), 2);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue