mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-27 02:01:42 +00:00
[wpimath] Add affine transformation constructors and getters to geometry API (#7430)
Fixes #7429.
This commit is contained in:
@@ -78,6 +78,13 @@ TEST(Rotation2dTest, Inequality) {
|
||||
EXPECT_NE(rot1, rot2);
|
||||
}
|
||||
|
||||
TEST(Rotation2dTest, ToMatrix) {
|
||||
Rotation2d before{20_deg};
|
||||
Rotation2d after{before.ToMatrix()};
|
||||
|
||||
EXPECT_EQ(before, after);
|
||||
}
|
||||
|
||||
TEST(Rotation2dTest, Constexpr) {
|
||||
constexpr Rotation2d defaultCtor;
|
||||
constexpr Rotation2d radianCtor{5_rad};
|
||||
|
||||
Reference in New Issue
Block a user