Skip to content

Commit 2e66bb9

Browse files
authored
conditionally disable tests on miri for taking way too long (#23677)
# Objective The PR CI takes a long time, particularly because of miri. maybe disable some tests on miri? related to #20818 (partitioning seems to lead to about 20 6-8minute slices if running on ubuntu, but miri also doesn't have a cached build, I'm not sure how much that could help; 20x 6 minutes is like a lot compared to 1x 25-30 minutes which I think was the reason @mockersf stopped pursuing that direction) ## Solution I've found 3 tests which take quite a bit longer than the rest. These are pretty low hanging fruits for reducing the time miri takes to test, HOWEVER I'm not sure if these tests benefit from miri (especially the toctou one) and should definitely run on miri. Edit: looks like this doesn't result in any meaningful difference because now the windows build is the bottleneck
1 parent c6bb950 commit 2e66bb9

3 files changed

Lines changed: 3 additions & 0 deletions

File tree

crates/bevy_ecs/src/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2064,6 +2064,7 @@ mod tests {
20642064
}
20652065

20662066
#[test]
2067+
#[cfg_attr(miri, ignore = "This test takes ~460s on CI")]
20672068
fn queue_register_component_toctou() {
20682069
for _ in 0..1000 {
20692070
let w = World::new();

crates/bevy_ecs/src/query/iter.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3048,6 +3048,7 @@ mod tests {
30483048
struct Marker;
30493049

30503050
#[test]
3051+
#[cfg_attr(miri, ignore = "This test takes ~70s on CI")]
30513052
fn query_iter_sorts() {
30523053
let mut world = World::new();
30533054
for i in 0..100 {

crates/bevy_ecs/src/query/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,7 @@ mod tests {
157157
}
158158

159159
#[test]
160+
#[cfg_attr(miri, ignore = "This test takes ~170s on CI")]
160161
fn query_filtered_exactsizeiterator_len() {
161162
fn choose(n: usize, k: usize) -> usize {
162163
if n == 0 || k == 0 || n < k {

0 commit comments

Comments
 (0)