diff options
author | Bernard Normier <bernard@zeroc.com> | 2016-08-04 17:36:25 -0400 |
---|---|---|
committer | Bernard Normier <bernard@zeroc.com> | 2016-08-04 17:36:25 -0400 |
commit | dc2f88ef6643b235a82be44b0682b75b7534c5e6 (patch) | |
tree | d9084cd31009402bc5bad8ff4cd7e20f764387ea /cpp/test | |
parent | Refactored shared_from_this/enable_shared_from_this (diff) | |
download | ice-dc2f88ef6643b235a82be44b0682b75b7534c5e6.tar.bz2 ice-dc2f88ef6643b235a82be44b0682b75b7534c5e6.tar.xz ice-dc2f88ef6643b235a82be44b0682b75b7534c5e6.zip |
New TargetCompare template, renamed targetEquals to targetEqualTo
Diffstat (limited to 'cpp/test')
-rw-r--r-- | cpp/test/Ice/adapterDeactivation/AllTests.cpp | 2 | ||||
-rw-r--r-- | cpp/test/Ice/custom/AllTests.cpp | 26 | ||||
-rw-r--r-- | cpp/test/Ice/exceptions/AllTests.cpp | 2 | ||||
-rw-r--r-- | cpp/test/Ice/facets/AllTests.cpp | 2 | ||||
-rw-r--r-- | cpp/test/Ice/faultTolerance/AllTests.cpp | 2 | ||||
-rw-r--r-- | cpp/test/Ice/hold/AllTests.cpp | 4 | ||||
-rw-r--r-- | cpp/test/Ice/inheritance/AllTests.cpp | 160 | ||||
-rw-r--r-- | cpp/test/Ice/objects/AllTests.cpp | 2 | ||||
-rw-r--r-- | cpp/test/Ice/operations/Twoways.cpp | 2 | ||||
-rw-r--r-- | cpp/test/Ice/optional/AllTests.cpp | 16 | ||||
-rw-r--r-- | cpp/test/Ice/proxy/AllTests.cpp | 154 | ||||
-rw-r--r-- | cpp/test/Ice/retry/AllTests.cpp | 4 | ||||
-rw-r--r-- | cpp/test/Ice/servantLocator/AllTests.cpp | 2 | ||||
-rw-r--r-- | cpp/test/IceSSL/configuration/AllTests.cpp | 18 |
14 files changed, 198 insertions, 198 deletions
diff --git a/cpp/test/Ice/adapterDeactivation/AllTests.cpp b/cpp/test/Ice/adapterDeactivation/AllTests.cpp index 3a02ae53b68..3f2f0462247 100644 --- a/cpp/test/Ice/adapterDeactivation/AllTests.cpp +++ b/cpp/test/Ice/adapterDeactivation/AllTests.cpp @@ -27,7 +27,7 @@ allTests(const CommunicatorPtr& communicator) TestIntfPrxPtr obj = ICE_CHECKED_CAST(TestIntfPrx, base); test(obj); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(obj, base)); + test(Ice::targetEqualTo(obj, base)); #else test(obj == base); #endif diff --git a/cpp/test/Ice/custom/AllTests.cpp b/cpp/test/Ice/custom/AllTests.cpp index 997ef66b9bc..102760f040e 100644 --- a/cpp/test/Ice/custom/AllTests.cpp +++ b/cpp/test/Ice/custom/AllTests.cpp @@ -593,7 +593,7 @@ allTests(const Ice::CommunicatorPtr& communicator) Test::TestIntfPrxPtr t = ICE_CHECKED_CAST(Test::TestIntfPrx, base); test(t); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(t, base)); + test(Ice::targetEqualTo(t, base)); #else test(t == base); #endif @@ -1060,8 +1060,8 @@ allTests(const Ice::CommunicatorPtr& communicator) for(auto i: in) { - test(Ice::targetEquals(*op++, i)); - test(Ice::targetEquals(*rp++, i)); + test(Ice::targetEqualTo(*op++, i)); + test(Ice::targetEqualTo(*rp++, i)); } #else test(out == in); @@ -1085,8 +1085,8 @@ allTests(const Ice::CommunicatorPtr& communicator) for(auto i: in) { - test(Ice::targetEquals(*op++, i)); - test(Ice::targetEquals(*rp++, i)); + test(Ice::targetEqualTo(*op++, i)); + test(Ice::targetEqualTo(*rp++, i)); } #else test(out == in); @@ -1853,8 +1853,8 @@ allTests(const Ice::CommunicatorPtr& communicator) for(auto i: in) { - test(Ice::targetEquals(*op++, i)); - test(Ice::targetEquals(*rp++, i)); + test(Ice::targetEqualTo(*op++, i)); + test(Ice::targetEqualTo(*rp++, i)); } #else deque<Test::CPrx> out; @@ -1884,8 +1884,8 @@ allTests(const Ice::CommunicatorPtr& communicator) for(auto i: in) { - test(Ice::targetEquals(*op++, i)); - test(Ice::targetEquals(*rp++, i)); + test(Ice::targetEqualTo(*op++, i)); + test(Ice::targetEqualTo(*rp++, i)); } #else list<Test::CPrx> out; @@ -2951,8 +2951,8 @@ allTests(const Ice::CommunicatorPtr& communicator) auto rp = ret.begin(); for(auto i: in) { - test(Ice::targetEquals(*op++, i)); - test(Ice::targetEquals(*rp++, i)); + test(Ice::targetEqualTo(*op++, i)); + test(Ice::targetEqualTo(*rp++, i)); } done.set_value(true); }, @@ -2991,8 +2991,8 @@ allTests(const Ice::CommunicatorPtr& communicator) auto rp = ret.begin(); for(auto i: in) { - test(Ice::targetEquals(*op++, i)); - test(Ice::targetEquals(*rp++, i)); + test(Ice::targetEqualTo(*op++, i)); + test(Ice::targetEqualTo(*rp++, i)); } done.set_value(true); }, diff --git a/cpp/test/Ice/exceptions/AllTests.cpp b/cpp/test/Ice/exceptions/AllTests.cpp index 3f047784a12..990f735a805 100644 --- a/cpp/test/Ice/exceptions/AllTests.cpp +++ b/cpp/test/Ice/exceptions/AllTests.cpp @@ -690,7 +690,7 @@ allTests(const Ice::CommunicatorPtr& communicator) ThrowerPrxPtr thrower = ICE_CHECKED_CAST(ThrowerPrx, base); test(thrower); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(thrower, base)); + test(Ice::targetEqualTo(thrower, base)); #else test(thrower == base); #endif diff --git a/cpp/test/Ice/facets/AllTests.cpp b/cpp/test/Ice/facets/AllTests.cpp index 5b542de8a85..01cd33cf1d6 100644 --- a/cpp/test/Ice/facets/AllTests.cpp +++ b/cpp/test/Ice/facets/AllTests.cpp @@ -192,7 +192,7 @@ allTests(const Ice::CommunicatorPtr& communicator) d = ICE_CHECKED_CAST(DPrx, db); test(d); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(d, db)); + test(Ice::targetEqualTo(d, db)); #else test(d == db); #endif diff --git a/cpp/test/Ice/faultTolerance/AllTests.cpp b/cpp/test/Ice/faultTolerance/AllTests.cpp index f50229d8cdb..5a861677c08 100644 --- a/cpp/test/Ice/faultTolerance/AllTests.cpp +++ b/cpp/test/Ice/faultTolerance/AllTests.cpp @@ -126,7 +126,7 @@ allTests(const Ice::CommunicatorPtr& communicator, const vector<int>& ports) TestIntfPrxPtr obj = ICE_CHECKED_CAST(TestIntfPrx, base); test(obj); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(obj, base)); + test(Ice::targetEqualTo(obj, base)); #else test(obj == base); #endif diff --git a/cpp/test/Ice/hold/AllTests.cpp b/cpp/test/Ice/hold/AllTests.cpp index 789562c8d1f..d08764d57d8 100644 --- a/cpp/test/Ice/hold/AllTests.cpp +++ b/cpp/test/Ice/hold/AllTests.cpp @@ -93,7 +93,7 @@ allTests(const Ice::CommunicatorPtr& communicator) HoldPrxPtr hold = ICE_CHECKED_CAST(HoldPrx, base); test(hold); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(hold, base)); + test(Ice::targetEqualTo(hold, base)); #else test(hold == base); #endif @@ -101,7 +101,7 @@ allTests(const Ice::CommunicatorPtr& communicator) test(holdSerialized); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(holdSerialized, baseSerialized)); + test(Ice::targetEqualTo(holdSerialized, baseSerialized)); #else test(holdSerialized == baseSerialized); #endif diff --git a/cpp/test/Ice/inheritance/AllTests.cpp b/cpp/test/Ice/inheritance/AllTests.cpp index 3e6be927b77..6fc955d7eb8 100644 --- a/cpp/test/Ice/inheritance/AllTests.cpp +++ b/cpp/test/Ice/inheritance/AllTests.cpp @@ -27,7 +27,7 @@ allTests(const Ice::CommunicatorPtr& communicator) InitialPrxPtr initial = ICE_CHECKED_CAST(InitialPrx, base); test(initial); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(initial, base)); + test(Ice::targetEqualTo(initial, base)); #else test(initial == base); #endif @@ -39,12 +39,12 @@ allTests(const Ice::CommunicatorPtr& communicator) MA::CCPrxPtr cc = initial->ccop(); MA::CDPrxPtr cd = initial->cdop(); #ifdef ICE_CPP11_MAPPING - test(!Ice::targetEquals(ca, cb)); - test(!Ice::targetEquals(ca, cc)); - test(!Ice::targetEquals(ca, cd)); - test(!Ice::targetEquals(cb, cc)); - test(!Ice::targetEquals(cb, cd)); - test(!Ice::targetEquals(cc, cd)); + test(!Ice::targetEqualTo(ca, cb)); + test(!Ice::targetEqualTo(ca, cc)); + test(!Ice::targetEqualTo(ca, cd)); + test(!Ice::targetEqualTo(cb, cc)); + test(!Ice::targetEqualTo(cb, cd)); + test(!Ice::targetEqualTo(cc, cd)); #else test(ca != cb); test(ca != cc); @@ -61,11 +61,11 @@ allTests(const Ice::CommunicatorPtr& communicator) MB::IB2PrxPtr ib2 = initial->ib2op(); MA::ICPrxPtr ic = initial->icop(); #ifdef ICE_CPP11_MAPPING - test(!Ice::targetEquals(ia, ib1)); - test(!Ice::targetEquals(ia, ib2)); - test(!Ice::targetEquals(ia, ic)); - test(!Ice::targetEquals(ib1, ic)); - test(!Ice::targetEquals(ib2, ic)); + test(!Ice::targetEqualTo(ia, ib1)); + test(!Ice::targetEqualTo(ia, ib2)); + test(!Ice::targetEqualTo(ia, ic)); + test(!Ice::targetEqualTo(ib1, ic)); + test(!Ice::targetEqualTo(ib2, ic)); #else test(ia != ib1); test(ia != ib2); @@ -82,140 +82,140 @@ allTests(const Ice::CommunicatorPtr& communicator) cao = ca->caop(ca); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, ca)); + test(Ice::targetEqualTo(cao, ca)); #else test(cao == ca); #endif cao = ca->caop(cb); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cb)); + test(Ice::targetEqualTo(cao, cb)); #else test(cao == cb); #endif cao = ca->caop(cc); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cc)); + test(Ice::targetEqualTo(cao, cc)); #else test(cao == cc); #endif cao = cb->caop(ca); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, ca)); + test(Ice::targetEqualTo(cao, ca)); #else test(cao == ca); #endif cao = cb->caop(cb); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cb)); + test(Ice::targetEqualTo(cao, cb)); #else test(cao == cb); #endif cao = cb->caop(cc); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cc)); + test(Ice::targetEqualTo(cao, cc)); #else test(cao == cc); #endif cao = cc->caop(ca); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, ca)); + test(Ice::targetEqualTo(cao, ca)); #else test(cao == ca); #endif cao = cc->caop(cb); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cb)); + test(Ice::targetEqualTo(cao, cb)); #else test(cao == cb); #endif cao = cc->caop(cc); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cc)); + test(Ice::targetEqualTo(cao, cc)); #else test(cao == cc); #endif cao = cb->cbop(cb); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cb)); + test(Ice::targetEqualTo(cao, cb)); #else test(cao == cb); #endif cbo = cb->cbop(cb); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cbo, cb)); + test(Ice::targetEqualTo(cbo, cb)); #else test(cbo == cb); #endif cao = cb->cbop(cc); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cc)); + test(Ice::targetEqualTo(cao, cc)); #else test(cao == cc); #endif cbo = cb->cbop(cc); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cbo, cc)); + test(Ice::targetEqualTo(cbo, cc)); #else test(cbo == cc); #endif cao = cc->cbop(cb); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cb)); + test(Ice::targetEqualTo(cao, cb)); #else test(cao == cb); #endif cbo = cc->cbop(cb); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cbo, cb)); + test(Ice::targetEqualTo(cbo, cb)); #else test(cbo == cb); #endif cao = cc->cbop(cc); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cc)); + test(Ice::targetEqualTo(cao, cc)); #else test(cao == cc); #endif cbo = cc->cbop(cc); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cbo, cc)); + test(Ice::targetEqualTo(cbo, cc)); #else test(cbo == cc); #endif cao = cc->ccop(cc); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cc)); + test(Ice::targetEqualTo(cao, cc)); #else test(cao == cc); #endif cbo = cc->ccop(cc); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cbo, cc)); + test(Ice::targetEqualTo(cbo, cc)); #else test(cbo == cc); #endif cco = cc->ccop(cc); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cco, cc)); + test(Ice::targetEqualTo(cco, cc)); #else test(cco == cc); #endif @@ -229,251 +229,251 @@ allTests(const Ice::CommunicatorPtr& communicator) iao = ia->iaop(ia); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ia)); + test(Ice::targetEqualTo(iao, ia)); #else test(iao == ia); #endif iao = ia->iaop(ib1); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib1)); + test(Ice::targetEqualTo(iao, ib1)); #else test(iao == ib1); #endif iao = ia->iaop(ib2); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib2)); + test(Ice::targetEqualTo(iao, ib2)); #else test(iao == ib2); #endif iao = ia->iaop(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ic)); + test(Ice::targetEqualTo(iao, ic)); #else test(iao == ic); #endif iao = ib1->iaop(ia); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ia)); + test(Ice::targetEqualTo(iao, ia)); #else test(iao == ia); #endif iao = ib1->iaop(ib1); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib1)); + test(Ice::targetEqualTo(iao, ib1)); #else test(iao == ib1); #endif iao = ib1->iaop(ib2); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib2)); + test(Ice::targetEqualTo(iao, ib2)); #else test(iao == ib2); #endif iao = ib1->iaop(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ic)); + test(Ice::targetEqualTo(iao, ic)); #else test(iao == ic); #endif iao = ib2->iaop(ia); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ia)); + test(Ice::targetEqualTo(iao, ia)); #else test(iao == ia); #endif iao = ib2->iaop(ib1); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib1)); + test(Ice::targetEqualTo(iao, ib1)); #else test(iao == ib1); #endif iao = ib2->iaop(ib2); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib2)); + test(Ice::targetEqualTo(iao, ib2)); #else test(iao == ib2); #endif iao = ib2->iaop(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ic)); + test(Ice::targetEqualTo(iao, ic)); #else test(iao == ic); #endif iao = ic->iaop(ia); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ia)); + test(Ice::targetEqualTo(iao, ia)); #else test(iao == ia); #endif iao = ic->iaop(ib1); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib1)); + test(Ice::targetEqualTo(iao, ib1)); #else test(iao == ib1); #endif iao = ic->iaop(ib2); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib2)); + test(Ice::targetEqualTo(iao, ib2)); #else test(iao == ib2); #endif iao = ic->iaop(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ic)); + test(Ice::targetEqualTo(iao, ic)); #else test(iao == ic); #endif iao = ib1->ib1op(ib1); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib1)); + test(Ice::targetEqualTo(iao, ib1)); #else test(iao == ib1); #endif ib1o = ib1->ib1op(ib1); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib1o, ib1)); + test(Ice::targetEqualTo(ib1o, ib1)); #else test(ib1o == ib1); #endif iao = ib1->ib1op(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ic)); + test(Ice::targetEqualTo(iao, ic)); #else test(iao == ic); #endif ib1o = ib1->ib1op(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib1o, ic)); + test(Ice::targetEqualTo(ib1o, ic)); #else test(ib1o == ic); #endif iao = ic->ib1op(ib1); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib1)); + test(Ice::targetEqualTo(iao, ib1)); #else test(iao == ib1); #endif ib1o = ic->ib1op(ib1); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib1o, ib1)); + test(Ice::targetEqualTo(ib1o, ib1)); #else test(ib1o == ib1); #endif iao = ic->ib1op(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ic)); + test(Ice::targetEqualTo(iao, ic)); #else test(iao == ic); #endif ib1o = ic->ib1op(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib1o, ic)); + test(Ice::targetEqualTo(ib1o, ic)); #else test(ib1o == ic); #endif iao = ib2->ib2op(ib2); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib2)); + test(Ice::targetEqualTo(iao, ib2)); #else test(iao == ib2); #endif ib2o = ib2->ib2op(ib2); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib2o, ib2)); + test(Ice::targetEqualTo(ib2o, ib2)); #else test(ib2o == ib2); #endif iao = ib2->ib2op(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ic)); + test(Ice::targetEqualTo(iao, ic)); #else test(iao == ic); #endif ib2o = ib2->ib2op(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib2o, ic)); + test(Ice::targetEqualTo(ib2o, ic)); #else test(ib2o == ic); #endif iao = ic->ib2op(ib2); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ib2)); + test(Ice::targetEqualTo(iao, ib2)); #else test(iao == ib2); #endif ib2o = ic->ib2op(ib2); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib2o, ib2)); + test(Ice::targetEqualTo(ib2o, ib2)); #else test(ib2o == ib2); #endif iao = ic->ib2op(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ic)); + test(Ice::targetEqualTo(iao, ic)); #else test(iao == ic); #endif ib2o = ic->ib2op(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib2o, ic)); + test(Ice::targetEqualTo(ib2o, ic)); #else test(ib2o == ic); #endif iao = ic->icop(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, ic)); + test(Ice::targetEqualTo(iao, ic)); #else test(iao == ic); #endif ib1o = ic->icop(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib1o, ic)); + test(Ice::targetEqualTo(ib1o, ic)); #else test(ib1o == ic); #endif ib2o = ic->icop(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib2o, ic)); + test(Ice::targetEqualTo(ib2o, ic)); #else test(ib2o == ic); #endif ico = ic->icop(ic); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ico, ic)); + test(Ice::targetEqualTo(ico, ic)); #else test(ico == ic); #endif @@ -485,84 +485,84 @@ allTests(const Ice::CommunicatorPtr& communicator) cao = cd->caop(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cd)); + test(Ice::targetEqualTo(cao, cd)); #else test(cao == cd); #endif cbo = cd->cbop(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cbo, cd)); + test(Ice::targetEqualTo(cbo, cd)); #else test(cbo == cd); #endif cco = cd->ccop(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cco, cd)); + test(Ice::targetEqualTo(cco, cd)); #else test(cco == cd); #endif iao = cd->iaop(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, cd)); + test(Ice::targetEqualTo(iao, cd)); #else test(iao == cd); #endif ib1o = cd->ib1op(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib1o, cd)); + test(Ice::targetEqualTo(ib1o, cd)); #else test(ib1o == cd); #endif ib2o = cd->ib2op(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib2o, cd)); + test(Ice::targetEqualTo(ib2o, cd)); #else test(ib2o == cd); #endif cao = cd->cdop(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cao, cd)); + test(Ice::targetEqualTo(cao, cd)); #else test(cao == cd); #endif cbo = cd->cdop(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cbo, cd)); + test(Ice::targetEqualTo(cbo, cd)); #else test(cbo == cd); #endif cco = cd->cdop(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(cco, cd)); + test(Ice::targetEqualTo(cco, cd)); #else test(cco == cd); #endif iao = cd->cdop(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(iao, cd)); + test(Ice::targetEqualTo(iao, cd)); #else test(iao == cd); #endif ib1o = cd->cdop(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib1o, cd)); + test(Ice::targetEqualTo(ib1o, cd)); #else test(ib1o == cd); #endif ib2o = cd->cdop(cd); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(ib2o, cd)); + test(Ice::targetEqualTo(ib2o, cd)); #else test(ib2o == cd); #endif diff --git a/cpp/test/Ice/objects/AllTests.cpp b/cpp/test/Ice/objects/AllTests.cpp index 63da17959e3..414a8c59f45 100644 --- a/cpp/test/Ice/objects/AllTests.cpp +++ b/cpp/test/Ice/objects/AllTests.cpp @@ -74,7 +74,7 @@ allTests(const Ice::CommunicatorPtr& communicator) InitialPrxPtr initial = ICE_CHECKED_CAST(InitialPrx, base); test(initial); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(initial, base)); + test(Ice::targetEqualTo(initial, base)); #else test(initial == base); #endif diff --git a/cpp/test/Ice/operations/Twoways.cpp b/cpp/test/Ice/operations/Twoways.cpp index a8fbe72f7e9..0e501f435eb 100644 --- a/cpp/test/Ice/operations/Twoways.cpp +++ b/cpp/test/Ice/operations/Twoways.cpp @@ -389,7 +389,7 @@ twoways(const Ice::CommunicatorPtr& communicator, const Test::MyClassPrxPtr& p) test(rso.e == ICE_ENUM(MyEnum, enum2)); test(rso.s.s == "def"); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(so.p, p)); + test(Ice::targetEqualTo(so.p, p)); #else test(so.p == p); #endif diff --git a/cpp/test/Ice/optional/AllTests.cpp b/cpp/test/Ice/optional/AllTests.cpp index a3fbd96a8ee..72b6e4122cb 100644 --- a/cpp/test/Ice/optional/AllTests.cpp +++ b/cpp/test/Ice/optional/AllTests.cpp @@ -393,7 +393,7 @@ allTests(const Ice::CommunicatorPtr& communicator, bool) test(initial); #ifdef ICE_CPP11_MAPPING - test(targetEquals(initial, base)); + test(targetEqualTo(initial, base)); #else test(initial == base); #endif @@ -595,7 +595,7 @@ allTests(const Ice::CommunicatorPtr& communicator, bool) test(mo5->h == mo1->h); test(mo5->i == mo1->i); #ifdef ICE_CPP11_MAPPING - test(targetEquals(mo5->j.value(), mo1->j.value())); + test(targetEqualTo(mo5->j.value(), mo1->j.value())); #else test(mo5->j == mo1->j); #endif @@ -617,7 +617,7 @@ allTests(const Ice::CommunicatorPtr& communicator, bool) test(mo5->oops.value().size() == mo1->oops.value().size()); for(size_t i = 0; i< mo5->oops.value().size(); ++i) { - test(targetEquals(mo5->oops.value()[i], mo1->oops.value()[i])); + test(targetEqualTo(mo5->oops.value()[i], mo1->oops.value()[i])); } #else test(mo5->oops == mo1->oops); @@ -632,7 +632,7 @@ allTests(const Ice::CommunicatorPtr& communicator, bool) test(mo5->ioopd.value().size() == mo1->ioopd.value().size()); for(auto& v : mo5->ioopd.value()) { - test(targetEquals(mo1->ioopd.value()[v.first], v.second)); + test(targetEqualTo(mo1->ioopd.value()[v.first], v.second)); } #else test(mo5->ioopd == mo1->ioopd); @@ -671,7 +671,7 @@ allTests(const Ice::CommunicatorPtr& communicator, bool) test(mo7->h == mo1->h); test(!mo7->i); #ifdef ICE_CPP11_MAPPING - test(targetEquals(mo7->j.value(), mo1->j.value())); + test(targetEqualTo(mo7->j.value(), mo1->j.value())); #else test(mo7->j == mo1->j); #endif @@ -743,7 +743,7 @@ allTests(const Ice::CommunicatorPtr& communicator, bool) test(mo8->oops.value().size() == mo1->oops.value().size()); for(size_t i = 0; i< mo8->oops.value().size(); ++i) { - test(targetEquals(mo8->oops.value()[i], mo1->oops.value()[i])); + test(targetEqualTo(mo8->oops.value()[i], mo1->oops.value()[i])); } #else test(mo8->oops == mo1->oops); @@ -1461,7 +1461,7 @@ allTests(const Ice::CommunicatorPtr& communicator, bool) p2 = initial->opOneOptionalProxy(p1, p3); #ifdef ICE_CPP11_MAPPING - test(targetEquals(p2.value(), p1.value()) && targetEquals(p3.value(), p1.value())); + test(targetEqualTo(p2.value(), p1.value()) && targetEqualTo(p3.value(), p1.value())); #else test(p2 == p1 && p3 == p1); #endif @@ -1479,7 +1479,7 @@ allTests(const Ice::CommunicatorPtr& communicator, bool) in.endEncapsulation(); #ifdef ICE_CPP11_MAPPING - test(targetEquals(p2.value(), p1.value()) && targetEquals(p3.value(), p1.value())); + test(targetEqualTo(p2.value(), p1.value()) && targetEqualTo(p3.value(), p1.value())); #else test(p2 == p1 && p3 == p1); #endif diff --git a/cpp/test/Ice/proxy/AllTests.cpp b/cpp/test/Ice/proxy/AllTests.cpp index bcded5cb5b2..d967c33a0d2 100644 --- a/cpp/test/Ice/proxy/AllTests.cpp +++ b/cpp/test/Ice/proxy/AllTests.cpp @@ -553,146 +553,146 @@ allTests(const Ice::CommunicatorPtr& communicator) cout << "testing proxy comparison... " << flush; #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(communicator->stringToProxy("foo"), communicator->stringToProxy("foo"))); - test(!Ice::targetEquals(communicator->stringToProxy("foo"), communicator->stringToProxy("foo2"))); + test(Ice::targetEqualTo(communicator->stringToProxy("foo"), communicator->stringToProxy("foo"))); + test(Ice::targetNotEqualTo(communicator->stringToProxy("foo"), communicator->stringToProxy("foo2"))); test(Ice::targetLess(communicator->stringToProxy("foo"), communicator->stringToProxy("foo2"))); - test(!Ice::targetLess(communicator->stringToProxy("foo2"), communicator->stringToProxy("foo"))); + test(Ice::targetGreaterEqual(communicator->stringToProxy("foo2"), communicator->stringToProxy("foo"))); Ice::ObjectPrxPtr compObj = communicator->stringToProxy("foo"); - test(Ice::targetEquals(compObj->ice_facet("facet"), compObj->ice_facet("facet"))); - test(!Ice::targetEquals(compObj->ice_facet("facet"), compObj->ice_facet("facet1"))); + test(Ice::targetEqualTo(compObj->ice_facet("facet"), compObj->ice_facet("facet"))); + test(Ice::targetNotEqualTo(compObj->ice_facet("facet"), compObj->ice_facet("facet1"))); test(Ice::targetLess(compObj->ice_facet("facet"), compObj->ice_facet("facet1"))); - test(!Ice::targetLess(compObj->ice_facet("facet"), compObj->ice_facet("facet"))); + test(Ice::targetGreaterEqual(compObj->ice_facet("facet"), compObj->ice_facet("facet"))); - test(Ice::targetEquals(compObj->ice_oneway(), compObj->ice_oneway())); - test(!Ice::targetEquals(compObj->ice_oneway(), compObj->ice_twoway())); + test(Ice::targetEqualTo(compObj->ice_oneway(), compObj->ice_oneway())); + test(Ice::targetNotEqualTo(compObj->ice_oneway(), compObj->ice_twoway())); test(Ice::targetLess(compObj->ice_twoway(), compObj->ice_oneway())); - test(!Ice::targetLess(compObj->ice_oneway(), compObj->ice_twoway())); + test(Ice::targetGreaterEqual(compObj->ice_oneway(), compObj->ice_twoway())); - test(Ice::targetEquals(compObj->ice_secure(true), compObj->ice_secure(true))); - test(!Ice::targetEquals(compObj->ice_secure(false), compObj->ice_secure(true))); + test(Ice::targetEqualTo(compObj->ice_secure(true), compObj->ice_secure(true))); + test(Ice::targetNotEqualTo(compObj->ice_secure(false), compObj->ice_secure(true))); test(Ice::targetLess(compObj->ice_secure(false), compObj->ice_secure(true))); - test(!Ice::targetLess(compObj->ice_secure(true), compObj->ice_secure(false))); + test(Ice::targetGreaterEqual(compObj->ice_secure(true), compObj->ice_secure(false))); - test(Ice::targetEquals(compObj->ice_collocationOptimized(true), compObj->ice_collocationOptimized(true))); - test(!Ice::targetEquals(compObj->ice_collocationOptimized(false), compObj->ice_collocationOptimized(true))); + test(Ice::targetEqualTo(compObj->ice_collocationOptimized(true), compObj->ice_collocationOptimized(true))); + test(Ice::targetNotEqualTo(compObj->ice_collocationOptimized(false), compObj->ice_collocationOptimized(true))); test(Ice::targetLess(compObj->ice_collocationOptimized(false), compObj->ice_collocationOptimized(true))); - test(!Ice::targetLess(compObj->ice_collocationOptimized(true), compObj->ice_collocationOptimized(false))); + test(Ice::targetGreaterEqual(compObj->ice_collocationOptimized(true), compObj->ice_collocationOptimized(false))); - test(Ice::targetEquals(compObj->ice_connectionCached(true), compObj->ice_connectionCached(true))); - test(!Ice::targetEquals(compObj->ice_connectionCached(false), compObj->ice_connectionCached(true))); + test(Ice::targetEqualTo(compObj->ice_connectionCached(true), compObj->ice_connectionCached(true))); + test(Ice::targetNotEqualTo(compObj->ice_connectionCached(false), compObj->ice_connectionCached(true))); test(Ice::targetLess(compObj->ice_connectionCached(false), compObj->ice_connectionCached(true))); - test(!Ice::targetLess(compObj->ice_connectionCached(true), compObj->ice_connectionCached(false))); + test(Ice::targetGreaterEqual(compObj->ice_connectionCached(true), compObj->ice_connectionCached(false))); - test(Ice::targetEquals(compObj->ice_endpointSelection(Ice::Random), compObj->ice_endpointSelection(Ice::Random))); - test(!Ice::targetEquals(compObj->ice_endpointSelection(Ice::Random), compObj->ice_endpointSelection(Ice::Ordered))); + test(Ice::targetEqualTo(compObj->ice_endpointSelection(Ice::Random), compObj->ice_endpointSelection(Ice::Random))); + test(Ice::targetNotEqualTo(compObj->ice_endpointSelection(Ice::Random), compObj->ice_endpointSelection(Ice::Ordered))); test(Ice::targetLess(compObj->ice_endpointSelection(Ice::Random), compObj->ice_endpointSelection(Ice::Ordered))); - test(!Ice::targetLess(compObj->ice_endpointSelection(Ice::Ordered), compObj->ice_endpointSelection(Ice::Random))); + test(Ice::targetGreaterEqual(compObj->ice_endpointSelection(Ice::Ordered), compObj->ice_endpointSelection(Ice::Random))); - test(Ice::targetEquals(compObj->ice_connectionId("id2"), compObj->ice_connectionId("id2"))); - test(!Ice::targetEquals(compObj->ice_connectionId("id1"), compObj->ice_connectionId("id2"))); + test(Ice::targetEqualTo(compObj->ice_connectionId("id2"), compObj->ice_connectionId("id2"))); + test(Ice::targetNotEqualTo(compObj->ice_connectionId("id1"), compObj->ice_connectionId("id2"))); test(Ice::targetLess(compObj->ice_connectionId("id1"), compObj->ice_connectionId("id2"))); - test(!Ice::targetLess(compObj->ice_connectionId("id2"), compObj->ice_connectionId("id1"))); + test(Ice::targetGreaterEqual(compObj->ice_connectionId("id2"), compObj->ice_connectionId("id1"))); test(compObj->ice_connectionId("id1")->ice_getConnectionId() == "id1"); test(compObj->ice_connectionId("id2")->ice_getConnectionId() == "id2"); - test(Ice::targetEquals(compObj->ice_compress(true), compObj->ice_compress(true))); - test(!Ice::targetEquals(compObj->ice_compress(false), compObj->ice_compress(true))); + test(Ice::targetEqualTo(compObj->ice_compress(true), compObj->ice_compress(true))); + test(Ice::targetNotEqualTo(compObj->ice_compress(false), compObj->ice_compress(true))); test(Ice::targetLess(compObj->ice_compress(false), compObj->ice_compress(true))); - test(!Ice::targetLess(compObj->ice_compress(true), compObj->ice_compress(false))); + test(Ice::targetGreaterEqual(compObj->ice_compress(true), compObj->ice_compress(false))); - test(Ice::targetEquals(compObj->ice_timeout(20), compObj->ice_timeout(20))); - test(!Ice::targetEquals(compObj->ice_timeout(10), compObj->ice_timeout(20))); + test(Ice::targetEqualTo(compObj->ice_timeout(20), compObj->ice_timeout(20))); + test(Ice::targetNotEqualTo(compObj->ice_timeout(10), compObj->ice_timeout(20))); test(Ice::targetLess(compObj->ice_timeout(10), compObj->ice_timeout(20))); - test(!Ice::targetLess(compObj->ice_timeout(20), compObj->ice_timeout(10))); + test(Ice::targetGreaterEqual(compObj->ice_timeout(20), compObj->ice_timeout(10))); auto loc1 = Ice::uncheckedCast<Ice::LocatorPrx>(communicator->stringToProxy("loc1:default -p 10000")); auto loc2 = Ice::uncheckedCast<Ice::LocatorPrx>(communicator->stringToProxy("loc2:default -p 10000")); - test(Ice::targetEquals(compObj->ice_locator(0), compObj->ice_locator(0))); - test(Ice::targetEquals(compObj->ice_locator(loc1), compObj->ice_locator(loc1))); - test(!Ice::targetEquals(compObj->ice_locator(loc1), compObj->ice_locator(0))); - test(!Ice::targetEquals(compObj->ice_locator(0), compObj->ice_locator(loc2))); - test(!Ice::targetEquals(compObj->ice_locator(loc1), compObj->ice_locator(loc2))); + test(Ice::targetEqualTo(compObj->ice_locator(0), compObj->ice_locator(0))); + test(Ice::targetEqualTo(compObj->ice_locator(loc1), compObj->ice_locator(loc1))); + test(Ice::targetNotEqualTo(compObj->ice_locator(loc1), compObj->ice_locator(0))); + test(Ice::targetNotEqualTo(compObj->ice_locator(0), compObj->ice_locator(loc2))); + test(Ice::targetNotEqualTo(compObj->ice_locator(loc1), compObj->ice_locator(loc2))); test(Ice::targetLess(compObj->ice_locator(0), compObj->ice_locator(loc1))); - test(!Ice::targetLess(compObj->ice_locator(loc1), compObj->ice_locator(0))); + test(Ice::targetGreaterEqual(compObj->ice_locator(loc1), compObj->ice_locator(0))); test(Ice::targetLess(compObj->ice_locator(loc1), compObj->ice_locator(loc2))); - test(!Ice::targetLess(compObj->ice_locator(loc2), compObj->ice_locator(loc1))); + test(Ice::targetGreaterEqual(compObj->ice_locator(loc2), compObj->ice_locator(loc1))); auto rtr1 = Ice::uncheckedCast<Ice::RouterPrx>(communicator->stringToProxy("rtr1:default -p 10000")); auto rtr2 = Ice::uncheckedCast<Ice::RouterPrx>(communicator->stringToProxy("rtr2:default -p 10000")); - test(Ice::targetEquals(compObj->ice_router(0), compObj->ice_router(0))); - test(Ice::targetEquals(compObj->ice_router(rtr1), compObj->ice_router(rtr1))); - test(!Ice::targetEquals(compObj->ice_router(rtr1), compObj->ice_router(0))); - test(!Ice::targetEquals(compObj->ice_router(0), compObj->ice_router(rtr2))); - test(!Ice::targetEquals(compObj->ice_router(rtr1), compObj->ice_router(rtr2))); + test(Ice::targetEqualTo(compObj->ice_router(0), compObj->ice_router(0))); + test(Ice::targetEqualTo(compObj->ice_router(rtr1), compObj->ice_router(rtr1))); + test(Ice::targetNotEqualTo(compObj->ice_router(rtr1), compObj->ice_router(0))); + test(Ice::targetNotEqualTo(compObj->ice_router(0), compObj->ice_router(rtr2))); + test(Ice::targetNotEqualTo(compObj->ice_router(rtr1), compObj->ice_router(rtr2))); test(Ice::targetLess(compObj->ice_router(0), compObj->ice_router(rtr1))); - test(!Ice::targetLess(compObj->ice_router(rtr1), compObj->ice_router(0))); + test(Ice::targetGreaterEqual(compObj->ice_router(rtr1), compObj->ice_router(0))); test(Ice::targetLess(compObj->ice_router(rtr1), compObj->ice_router(rtr2))); - test(!Ice::targetLess(compObj->ice_router(rtr2), compObj->ice_router(rtr1))); + test(Ice::targetGreaterEqual(compObj->ice_router(rtr2), compObj->ice_router(rtr1))); Ice::Context ctx1; ctx1["ctx1"] = "v1"; Ice::Context ctx2; ctx2["ctx2"] = "v2"; - test(Ice::targetEquals(compObj->ice_context(Ice::Context()), compObj->ice_context(Ice::Context()))); - test(Ice::targetEquals(compObj->ice_context(ctx1), compObj->ice_context(ctx1))); - test(!Ice::targetEquals(compObj->ice_context(ctx1), compObj->ice_context(Ice::Context()))); - test(!Ice::targetEquals(compObj->ice_context(Ice::Context()), compObj->ice_context(ctx2))); - test(!Ice::targetEquals(compObj->ice_context(ctx1), compObj->ice_context(ctx2))); + test(Ice::targetEqualTo(compObj->ice_context(Ice::Context()), compObj->ice_context(Ice::Context()))); + test(Ice::targetEqualTo(compObj->ice_context(ctx1), compObj->ice_context(ctx1))); + test(Ice::targetNotEqualTo(compObj->ice_context(ctx1), compObj->ice_context(Ice::Context()))); + test(Ice::targetNotEqualTo(compObj->ice_context(Ice::Context()), compObj->ice_context(ctx2))); + test(Ice::targetNotEqualTo(compObj->ice_context(ctx1), compObj->ice_context(ctx2))); test(Ice::targetLess(compObj->ice_context(ctx1), compObj->ice_context(ctx2))); - test(!Ice::targetLess(compObj->ice_context(ctx2), compObj->ice_context(ctx1))); + test(Ice::targetGreaterEqual(compObj->ice_context(ctx2), compObj->ice_context(ctx1))); - test(Ice::targetEquals(compObj->ice_preferSecure(true), compObj->ice_preferSecure(true))); - test(!Ice::targetEquals(compObj->ice_preferSecure(true), compObj->ice_preferSecure(false))); + test(Ice::targetEqualTo(compObj->ice_preferSecure(true), compObj->ice_preferSecure(true))); + test(Ice::targetNotEqualTo(compObj->ice_preferSecure(true), compObj->ice_preferSecure(false))); test(Ice::targetLess(compObj->ice_preferSecure(false), compObj->ice_preferSecure(true))); - test(!Ice::targetLess(compObj->ice_preferSecure(true), compObj->ice_preferSecure(false))); + test(Ice::targetGreaterEqual(compObj->ice_preferSecure(true), compObj->ice_preferSecure(false))); auto compObj1 = communicator->stringToProxy("foo:tcp -h 127.0.0.1 -p 10000"); auto compObj2 = communicator->stringToProxy("foo:tcp -h 127.0.0.1 -p 10001"); - test(!Ice::targetEquals(compObj1, compObj2)); + test(Ice::targetNotEqualTo(compObj1, compObj2)); test(Ice::targetLess(compObj1, compObj2)); - test(!Ice::targetLess(compObj2, compObj1)); + test(Ice::targetGreaterEqual(compObj2, compObj1)); compObj1 = communicator->stringToProxy("foo@MyAdapter1"); compObj2 = communicator->stringToProxy("foo@MyAdapter2"); - test(!Ice::targetEquals(compObj1, compObj2)); + test(Ice::targetNotEqualTo(compObj1, compObj2)); test(Ice::targetLess(compObj1, compObj2)); - test(!Ice::targetLess(compObj2, compObj1)); + test(Ice::targetGreaterEqual(compObj2, compObj1)); - test(Ice::targetEquals(compObj1->ice_locatorCacheTimeout(20), compObj1->ice_locatorCacheTimeout(20))); - test(!Ice::targetEquals(compObj1->ice_locatorCacheTimeout(10), compObj1->ice_locatorCacheTimeout(20))); + test(Ice::targetEqualTo(compObj1->ice_locatorCacheTimeout(20), compObj1->ice_locatorCacheTimeout(20))); + test(Ice::targetNotEqualTo(compObj1->ice_locatorCacheTimeout(10), compObj1->ice_locatorCacheTimeout(20))); test(Ice::targetLess(compObj1->ice_locatorCacheTimeout(10), compObj1->ice_locatorCacheTimeout(20))); - test(!Ice::targetLess(compObj1->ice_locatorCacheTimeout(20), compObj1->ice_locatorCacheTimeout(10))); + test(Ice::targetGreaterEqual(compObj1->ice_locatorCacheTimeout(20), compObj1->ice_locatorCacheTimeout(10))); - test(Ice::targetEquals(compObj1->ice_invocationTimeout(20), compObj1->ice_invocationTimeout(20))); - test(!Ice::targetEquals(compObj1->ice_invocationTimeout(10), compObj1->ice_invocationTimeout(20))); + test(Ice::targetEqualTo(compObj1->ice_invocationTimeout(20), compObj1->ice_invocationTimeout(20))); + test(Ice::targetNotEqualTo(compObj1->ice_invocationTimeout(10), compObj1->ice_invocationTimeout(20))); test(Ice::targetLess(compObj1->ice_invocationTimeout(10), compObj1->ice_invocationTimeout(20))); - test(!Ice::targetLess(compObj1->ice_invocationTimeout(20), compObj1->ice_invocationTimeout(10))); + test(Ice::targetGreaterEqual(compObj1->ice_invocationTimeout(20), compObj1->ice_invocationTimeout(10))); compObj1 = communicator->stringToProxy("foo:tcp -h 127.0.0.1 -p 1000"); compObj2 = communicator->stringToProxy("foo@MyAdapter1"); - test(!Ice::targetEquals(compObj1, compObj2)); + test(Ice::targetNotEqualTo(compObj1, compObj2)); test(Ice::targetLess(compObj1, compObj2)); - test(!Ice::targetLess(compObj2, compObj1)); + test(Ice::targetGreaterEqual(compObj2, compObj1)); Ice::EndpointSeq endpts1 = communicator->stringToProxy("foo:tcp -h 127.0.0.1 -p 10000")->ice_getEndpoints(); Ice::EndpointSeq endpts2 = communicator->stringToProxy("foo:tcp -h 127.0.0.1 -p 10001")->ice_getEndpoints(); - test(endpts1.size() != endpts2.size() || !equal(endpts1.begin(), endpts1.end(), endpts2.begin(), Ice::TargetEquals<shared_ptr<Ice::Endpoint>>())); - test(lexicographical_compare(endpts1.begin(), endpts1.end(), endpts2.begin(), endpts2.end(), Ice::TargetLess<shared_ptr<Ice::Endpoint>>())); - test(!lexicographical_compare(endpts2.begin(), endpts2.end(), endpts1.begin(), endpts1.end(), Ice::TargetLess<shared_ptr<Ice::Endpoint>>())); + test(endpts1.size() != endpts2.size() || !equal(endpts1.begin(), endpts1.end(), endpts2.begin(), Ice::TargetCompare<shared_ptr<Ice::Endpoint>, std::equal_to>())); + test(lexicographical_compare(endpts1.begin(), endpts1.end(), endpts2.begin(), endpts2.end(), Ice::TargetCompare<shared_ptr<Ice::Endpoint>, std::less>())); + test(!lexicographical_compare(endpts2.begin(), endpts2.end(), endpts1.begin(), endpts1.end(), Ice::TargetCompare<shared_ptr<Ice::Endpoint>, std::less>())); Ice::EndpointSeq endpts3 = communicator->stringToProxy("foo:tcp -h 127.0.0.1 -p 10000")->ice_getEndpoints(); - test(endpts1.size() == endpts3.size() && equal(endpts1.begin(), endpts1.end(), endpts3.begin(), Ice::TargetEquals<shared_ptr<Ice::Endpoint>>())); + test(endpts1.size() == endpts3.size() && equal(endpts1.begin(), endpts1.end(), endpts3.begin(), Ice::TargetCompare<shared_ptr<Ice::Endpoint>, std::equal_to>())); - test(Ice::targetEquals(compObj1->ice_encodingVersion(Ice::Encoding_1_0), compObj1->ice_encodingVersion(Ice::Encoding_1_0))); - test(!Ice::targetEquals(compObj1->ice_encodingVersion(Ice::Encoding_1_0), compObj1->ice_encodingVersion(Ice::Encoding_1_1))); + test(Ice::targetEqualTo(compObj1->ice_encodingVersion(Ice::Encoding_1_0), compObj1->ice_encodingVersion(Ice::Encoding_1_0))); + test(Ice::targetNotEqualTo(compObj1->ice_encodingVersion(Ice::Encoding_1_0), compObj1->ice_encodingVersion(Ice::Encoding_1_1))); test(Ice::targetLess(compObj->ice_encodingVersion(Ice::Encoding_1_0), compObj->ice_encodingVersion(Ice::Encoding_1_1))); - test(!Ice::targetLess(compObj->ice_encodingVersion(Ice::Encoding_1_1), compObj->ice_encodingVersion(Ice::Encoding_1_0))); + test(Ice::targetGreaterEqual(compObj->ice_encodingVersion(Ice::Encoding_1_1), compObj->ice_encodingVersion(Ice::Encoding_1_0))); // // TODO: Ideally we should also test comparison of fixed proxies. @@ -706,9 +706,9 @@ allTests(const Ice::CommunicatorPtr& communicator) auto derived = Ice::checkedCast<Test::MyDerivedClassPrx>(cl); test(derived); - test(Ice::targetEquals(cl, base)); - test(Ice::targetEquals(derived, base)); - test(Ice::targetEquals(cl, derived)); + test(Ice::targetEqualTo(cl, base)); + test(Ice::targetEqualTo(derived, base)); + test(Ice::targetEqualTo(cl, derived)); auto loc = Ice::checkedCast<Ice::LocatorPrx>(base); test(loc == nullptr); @@ -720,8 +720,8 @@ allTests(const Ice::CommunicatorPtr& communicator) auto obj = Ice::checkedCast<Ice::ObjectPrx>(derived); test(cl2); test(obj); - test(Ice::targetEquals(cl2, obj)); - test(Ice::targetEquals(cl2, derived)); + test(Ice::targetEqualTo(cl2, obj)); + test(Ice::targetEqualTo(cl2, derived)); #else test(communicator->stringToProxy("foo") == communicator->stringToProxy("foo")); test(communicator->stringToProxy("foo") != communicator->stringToProxy("foo2")); diff --git a/cpp/test/Ice/retry/AllTests.cpp b/cpp/test/Ice/retry/AllTests.cpp index bf2469e3be9..27283363481 100644 --- a/cpp/test/Ice/retry/AllTests.cpp +++ b/cpp/test/Ice/retry/AllTests.cpp @@ -102,14 +102,14 @@ allTests(const Ice::CommunicatorPtr& communicator, const Ice::CommunicatorPtr& c RetryPrxPtr retry1 = ICE_CHECKED_CAST(RetryPrx, base1); test(retry1); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(retry1, base1)); + test(Ice::targetEqualTo(retry1, base1)); #else test(retry1 == base1); #endif RetryPrxPtr retry2 = ICE_CHECKED_CAST(RetryPrx, base2); test(retry2); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(retry2, base2)); + test(Ice::targetEqualTo(retry2, base2)); #else test(retry2 == base2); #endif diff --git a/cpp/test/Ice/servantLocator/AllTests.cpp b/cpp/test/Ice/servantLocator/AllTests.cpp index c028bdd6562..18ec1b87d1a 100644 --- a/cpp/test/Ice/servantLocator/AllTests.cpp +++ b/cpp/test/Ice/servantLocator/AllTests.cpp @@ -227,7 +227,7 @@ allTests(const CommunicatorPtr& communicator) TestIntfPrxPtr obj = ICE_CHECKED_CAST(TestIntfPrx, base); test(obj); #ifdef ICE_CPP11_MAPPING - test(Ice::targetEquals(obj, base)); + test(Ice::targetEqualTo(obj, base)); #else test(obj == base); #endif diff --git a/cpp/test/IceSSL/configuration/AllTests.cpp b/cpp/test/IceSSL/configuration/AllTests.cpp index 35d60785ebf..4fa930b62dd 100644 --- a/cpp/test/IceSSL/configuration/AllTests.cpp +++ b/cpp/test/IceSSL/configuration/AllTests.cpp @@ -24,9 +24,9 @@ #endif #ifdef ICE_CPP11_MAPPING -# define ICE_TARGET_EQUALS(A,B) Ice::targetEquals(A, B) +# define ICE_TARGET_EQUAL_TO(A,B) Ice::targetEqualTo(A, B) #else -# define ICE_TARGET_EQUALS(A,B) A == B +# define ICE_TARGET_EQUAL_TO(A,B) A == B #endif using namespace std; @@ -753,8 +753,8 @@ allTests(const CommunicatorPtr& communicator, const string& testDir, bool p12) // Validate some aspects of the Certificate class. // IceSSL::CertificatePtr serverCert = IceSSL::Certificate::load(defaultDir + "/s_rsa_ca1_pub.pem"); - test(ICE_TARGET_EQUALS(IceSSL::Certificate::decode(serverCert->encode()), serverCert)); - test(ICE_TARGET_EQUALS(serverCert, serverCert)); + test(ICE_TARGET_EQUAL_TO(IceSSL::Certificate::decode(serverCert->encode()), serverCert)); + test(ICE_TARGET_EQUAL_TO(serverCert, serverCert)); #if !defined(__APPLE__) || TARGET_OS_IPHONE == 0 test(serverCert->checkValidity()); test(!serverCert->checkValidity(IceUtil::Time::seconds(0))); @@ -762,7 +762,7 @@ allTests(const CommunicatorPtr& communicator, const string& testDir, bool p12) IceSSL::CertificatePtr caCert = IceSSL::Certificate::load(defaultDir + "/cacert1.pem"); IceSSL::CertificatePtr caCert2 = IceSSL::Certificate::load(defaultDir + "/cacert2.pem"); - test(ICE_TARGET_EQUALS(caCert, caCert)); + test(ICE_TARGET_EQUAL_TO(caCert, caCert)); #if !defined(__APPLE__) || TARGET_OS_IPHONE == 0 test(caCert->checkValidity()); test(!caCert->checkValidity(IceUtil::Time::seconds(0))); @@ -777,11 +777,11 @@ allTests(const CommunicatorPtr& communicator, const string& testDir, bool p12) test(info->nativeCerts.size() == 2); test(info->verified); - test(ICE_TARGET_EQUALS(caCert, info->nativeCerts[1])); - test(ICE_TARGET_EQUALS(serverCert, info->nativeCerts[0])); + test(ICE_TARGET_EQUAL_TO(caCert, info->nativeCerts[1])); + test(ICE_TARGET_EQUAL_TO(serverCert, info->nativeCerts[0])); - test(!(ICE_TARGET_EQUALS(serverCert, info->nativeCerts[1]))); - test(!(ICE_TARGET_EQUALS(caCert, info->nativeCerts[0]))); + test(!(ICE_TARGET_EQUAL_TO(serverCert, info->nativeCerts[1]))); + test(!(ICE_TARGET_EQUAL_TO(caCert, info->nativeCerts[0]))); #if !defined(__APPLE__) || TARGET_OS_IPHONE == 0 test(info->nativeCerts[0]->checkValidity() && info->nativeCerts[1]->checkValidity()); |