blob: 374b5bfc39ef677df03065c7e951d1cbdc7eeb94 [file] [log] [blame]
Parker Schuh0ff777c2017-02-19 15:01:13 -08001#include "aos/vision/blob/transpose.h"
Parker Schuh0ff777c2017-02-19 15:01:13 -08002
3#include <algorithm>
4#include <string>
Austin Schuh60e77942022-05-16 17:48:24 -07005
6#include "aos/vision/blob/test_utils.h"
Parker Schuh0ff777c2017-02-19 15:01:13 -08007#include "gtest/gtest.h"
8
9namespace aos {
10namespace vision {
11
12TEST(TransposeTest, Tranpspose) {
13 RangeImage img = LoadFromTestData(20, R"(
14 -----------
15 ----- ----
16 ------------
17 -------------
18 ------------
19 ----------
20 ------------
21 ---------
22)");
23
24 auto b = Transpose(img);
25 auto c = Transpose(b);
26 EXPECT_EQ(ShortDebugPrint({img}), ShortDebugPrint({c}));
27}
28
29} // namespace vision
30} // namespace aos