Home | History | Annotate | Download | only in tests

Lines Matching refs:data0

19     TestRC    data0, data1;
26 dict.set("foo", &data0);
27 REPORTER_ASSERT(reporter, &data0 == dict.find("foo"));
28 REPORTER_ASSERT(reporter, 2 == data0.getRefCnt());
30 dict.set("foo", &data0);
31 REPORTER_ASSERT(reporter, &data0 == dict.find("foo"));
32 REPORTER_ASSERT(reporter, 2 == data0.getRefCnt());
36 REPORTER_ASSERT(reporter, 1 == data0.getRefCnt());
41 REPORTER_ASSERT(reporter, 1 == data0.getRefCnt());
44 dict.set("foo", &data0);
46 REPORTER_ASSERT(reporter, &data0 == dict.find("foo"));
48 REPORTER_ASSERT(reporter, 2 == data0.getRefCnt());
54 REPORTER_ASSERT(reporter, 1 == data0.getRefCnt());
60 REPORTER_ASSERT(reporter, 1 == data0.getRefCnt());
66 REPORTER_ASSERT(reporter, 1 == data0.getRefCnt());
67 d.set("foo", &data0);
68 REPORTER_ASSERT(reporter, &data0 == d.find("foo"));
69 REPORTER_ASSERT(reporter, 2 == data0.getRefCnt());
70 // let d go out of scope still with a ref on data0
72 // be sure d's destructor lowered data0's owner count back to 1
73 REPORTER_ASSERT(reporter, 1 == data0.getRefCnt());