MCPcopy Create free account
hub / github.com/arrayfire/arrayfire / TYPED_TEST

Function TYPED_TEST

test/array.cpp:53–66  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

51}
52
53TYPED_TEST(Array, ConstructorEmptyDim4) {
54 SUPPORTED_TYPE_CHECK(TypeParam);
55
56 dtype type = (dtype)dtype_traits<TypeParam>::af_type;
57 dim4 dims(3, 3, 3, 3);
58 array a(dims, type);
59 EXPECT_EQ(4u, a.numdims());
60 EXPECT_EQ(dim_t(3), a.dims(0));
61 EXPECT_EQ(dim_t(3), a.dims(1));
62 EXPECT_EQ(dim_t(3), a.dims(2));
63 EXPECT_EQ(dim_t(3), a.dims(3));
64 EXPECT_EQ(dim_t(81), a.elements());
65 EXPECT_EQ(type, a.type());
66}
67
68TYPED_TEST(Array, ConstructorEmpty1D) {
69 SUPPORTED_TYPE_CHECK(TypeParam);

Callers

nothing calls this directly

Calls 7

randuFunction · 0.85
numdimsMethod · 0.80
typeMethod · 0.80
hostMethod · 0.80
dim4Class · 0.50
dimsMethod · 0.45
elementsMethod · 0.45

Tested by

no test coverage detected