| 23 | namespace bc = boost::compute; |
| 24 | |
| 25 | BOOST_AUTO_TEST_CASE(partition_int) |
| 26 | { |
| 27 | int dataset[] = {1, 1, -2, 0, 5, -1, 2, 4, 0, -1}; |
| 28 | bc::vector<bc::int_> vector(dataset, dataset + 10, queue); |
| 29 | |
| 30 | bc::vector<bc::int_>::iterator iter = |
| 31 | bc::stable_partition(vector.begin(), vector.begin() + 10, |
| 32 | bc::_1 > 0, queue); |
| 33 | |
| 34 | CHECK_RANGE_EQUAL(int, 10, vector, (1, 1, 5, 2, 4, -2, 0, -1, 0, -1)); |
| 35 | BOOST_VERIFY(iter == vector.begin()+5); |
| 36 | } |
| 37 | |
| 38 | BOOST_AUTO_TEST_SUITE_END() |
nothing calls this directly
no test coverage detected