MCPcopy Create free account
hub / github.com/boostorg/compute / BOOST_AUTO_TEST_CASE

Function BOOST_AUTO_TEST_CASE

test/test_unique_copy.cpp:23–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

21namespace compute = boost::compute;
22
23BOOST_AUTO_TEST_CASE(unique_copy_int)
24{
25 int data[] = {1, 6, 6, 4, 2, 2, 4};
26
27 bc::vector<int> input(data, data + 7, queue);
28 bc::vector<int> result(5, context);
29
30 bc::vector<int>::iterator iter =
31 bc::unique_copy(input.begin(), input.end(), result.begin(), queue);
32
33 BOOST_VERIFY(iter == result.begin() + 5);
34 CHECK_RANGE_EQUAL(int, 5, result, (1, 6, 4, 2, 4));
35}
36
37BOOST_AUTO_TEST_SUITE_END()

Callers

nothing calls this directly

Calls 3

unique_copyFunction · 0.85
beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected