Skip to content

Commit bbad0ce

Browse files
committed
Tets change, check size of cache before calling the second server
* TAO/tests/Transport_Idle_Timeout/Echo_i.cpp: * TAO/tests/Transport_Idle_Timeout/client_multiple.cpp:
1 parent 2eaaa97 commit bbad0ce

2 files changed

Lines changed: 5 additions & 7 deletions

File tree

TAO/tests/Transport_Idle_Timeout/Echo_i.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,8 @@ Echo_i::ping (::CORBA::Long sleep_time, ::CORBA::Long cache_size_expected, ::Tes
6161
bool ok = true;
6262
sleep_with_reactor (this->orb_, sleep_time);
6363

64+
ok &= check ("ping", cache_size(this->orb_), cache_size_expected);
65+
6466
if (!CORBA::is_nil(server))
6567
{
6668
ACE_DEBUG ((LM_DEBUG,
@@ -72,10 +74,6 @@ Echo_i::ping (::CORBA::Long sleep_time, ::CORBA::Long cache_size_expected, ::Tes
7274
}
7375
ok &= check ("ping_second", cache_size(this->orb_), cache_size_expected_in_server1);
7476
}
75-
else
76-
{
77-
ok &= check ("ping", cache_size(this->orb_), cache_size_expected);
78-
}
7977
return ok;
8078
}
8179

TAO/tests/Transport_Idle_Timeout/client_multiple.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ tc1_basic_idle_close (CORBA::ORB_ptr orb, Test::Echo_ptr echo, Test::Echo_ptr ec
141141
bool ok = true;
142142

143143
// --- Step 1: establish a transport ---
144-
ok &= echo->ping (0, 2, echo2, 0, 2, 1);
144+
ok &= echo->ping (0, 1, echo2, 0, 2, 1);
145145

146146
ok &= check ("TC-1 after ping (expect 1)", cache_size(orb), 1);
147147

@@ -159,7 +159,7 @@ tc1_basic_idle_close (CORBA::ORB_ptr orb, Test::Echo_ptr echo, Test::Echo_ptr ec
159159

160160
// Make another call, but let wait sleep_sec after the ping to the second server,
161161
// which means the call takes longer as the idle time.
162-
ok &= echo->ping (0, 2, echo2, sleep_sec, 0, 0);
162+
ok &= echo->ping (0, 1, echo2, sleep_sec, 0, 0);
163163

164164
ok &= check ("TC-1 after ping longer as timeout (expect 1)", cache_size(orb), 1);
165165

@@ -186,7 +186,7 @@ tc2_reconnect (CORBA::ORB_ptr orb, Test::Echo_ptr echo, Test::Echo_ptr echo2)
186186

187187
// A new ping must succeed without TRANSIENT even though TC-1 caused the
188188
// server to close the connection. TAO's reconnect logic handles this.
189-
ok &= echo->ping (0, 2, echo2, 0, 2, 1);
189+
ok &= echo->ping (0, 1, echo2, 0, 2, 1);
190190

191191
ok &= check ("TC-2 after reconnect ping (expect 1)", cache_size(orb), 1);
192192

0 commit comments

Comments
 (0)