GPU: rename the second test module in host.rs so the tests compile
cargo test --workspace does not compile on main: host.rs declares
#[cfg(test)] mod tests twice, once near the top for the warp adapter test and
once at the end for the Batch::texture_due tests, so rustc rejects the crate
with E0428 before running anything:
error[E0428]: the name ests is defined multiple times
--> crates\victory-gpu\src\host.rs:1974:1
The second block only touches Batch, so it becomes mod batch and keeps its
two tests. cargo test -p victory-gpu --lib goes from "could not compile" to
43 passed, 0 failed, 1 ignored, and cargo test --workspace compiles again.
Nothing else changes: one line, no test bodies touched.
This commit is contained in:
1 parent
23a6fe2539
commit
7c59cc6f48
1 file changed
+1
-1
@@ -1971,7 +1971,7 @@ fn pump() {
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
mod batch { // Batch::texture_due lives here; `mod tests` is already taken at the top of this file
|
||||
use super::Batch;
|
||||
use std::sync::Arc;
|
||||
|
||||
|
||||
Reference in new issue
Block a user