mirror of
https://github.com/bevyengine/bevy
synced 2024-11-26 06:30:19 +00:00
bevy_reflect: remove glam
from a test which is active without the glam feature (#5195)
# Objective `glam` is an optional feature in `bevy_reflect` and there is a separate `mod test { #[cfg(feature = "glam")] mod glam { .. }}`. The `reflect_downcast` test is not in that module and doesn't depend on glam, which breaks `cargo test -p bevy_reflect` without the `glam` feature. ## Solution - Remove the glam types from the test, they're not relevant to it
This commit is contained in:
parent
179f719553
commit
4d05eb19be
1 changed files with 3 additions and 10 deletions
|
@ -493,7 +493,6 @@ mod tests {
|
|||
#[derive(Reflect, Clone, Debug, PartialEq)]
|
||||
struct Bar {
|
||||
y: u8,
|
||||
z: ::glam::Mat4,
|
||||
}
|
||||
|
||||
#[derive(Reflect, Clone, Debug, PartialEq)]
|
||||
|
@ -502,21 +501,15 @@ mod tests {
|
|||
s: String,
|
||||
b: Bar,
|
||||
u: usize,
|
||||
t: (Vec3, String),
|
||||
t: ([f32; 3], String),
|
||||
}
|
||||
|
||||
let foo = Foo {
|
||||
x: 123,
|
||||
s: "String".to_string(),
|
||||
b: Bar {
|
||||
y: 255,
|
||||
z: ::glam::Mat4::from_cols_array(&[
|
||||
0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0, 11.0, 12.0, 13.0, 14.0,
|
||||
15.0,
|
||||
]),
|
||||
},
|
||||
b: Bar { y: 255 },
|
||||
u: 1111111111111,
|
||||
t: (Vec3::new(3.0, 2.0, 1.0), "Tuple String".to_string()),
|
||||
t: ([3.0, 2.0, 1.0], "Tuple String".to_string()),
|
||||
};
|
||||
|
||||
let foo2: Box<dyn Reflect> = Box::new(foo.clone());
|
||||
|
|
Loading…
Reference in a new issue