MCPcopy Create free account
hub / github.com/antmachineintelligence/mtgbmcode / BOOST_AUTO_TEST_CASE

Function BOOST_AUTO_TEST_CASE

compute/test/test_context.cpp:22–38  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20namespace compute = boost::compute;
21
22BOOST_AUTO_TEST_CASE(construct_from_cl_context)
23{
24 cl_device_id id = device.id();
25
26 // create cl_context
27 cl_context ctx = clCreateContext(0, 1, &id, 0, 0, 0);
28 BOOST_VERIFY(ctx);
29
30 // create boost::compute::context
31 boost::compute::context context(ctx);
32
33 // check context
34 BOOST_CHECK(cl_context(context) == ctx);
35
36 // cleanup cl_context
37 clReleaseContext(ctx);
38}
39
40#ifndef BOOST_COMPUTE_NO_RVALUE_REFERENCES
41BOOST_AUTO_TEST_CASE(move_constructor)

Callers

nothing calls this directly

Calls 5

idMethod · 0.45
sizeMethod · 0.45
devicesMethod · 0.45
get_devicesMethod · 0.45
device_countMethod · 0.45

Tested by

no test coverage detected