Skip to content

Commit e7fea05

Browse files
committed
Remove test about target counts, as tab number is unpredictable (empty tabs may linger)
1 parent 560e189 commit e7fea05

File tree

1 file changed

+0
-29
lines changed

1 file changed

+0
-29
lines changed

src/jvmTest/kotlin/ZenikaIntegrationTests.kt

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -34,26 +34,6 @@ class ZenikaIntegrationTests : LocalIntegrationTestBase() {
3434
override fun missingExpiresInCookie() {
3535
}
3636

37-
@Suppress("DEPRECATION") // the point is to test this deprecated API
38-
@Test
39-
fun httpTabEndpoints_basic() {
40-
runBlockingWithTimeout {
41-
val chrome = chromeHttp()
42-
chrome.closeAllTargets()
43-
44-
val newTab = chrome.newTab()
45-
assertEquals("about:blank", newTab.url.trimEnd('/'))
46-
assertTargetCount(1, chrome.targets())
47-
chrome.closeTab(newTab.id)
48-
49-
assertTargetCount(0, chrome.targets())
50-
chrome.newTab()
51-
chrome.newTab()
52-
chrome.closeAllTargets()
53-
assertTargetCount(0, chrome.targets())
54-
}
55-
}
56-
5737
@Suppress("DEPRECATION") // the point is to test this deprecated API
5838
@Test
5939
fun httpTabEndpoints_newTabWithCustomUrl() {
@@ -78,13 +58,4 @@ class ZenikaIntegrationTests : LocalIntegrationTestBase() {
7858
)
7959
}
8060
}
81-
82-
private fun assertTargetCount(expected: Int, currentTargets: List<ChromeDPTarget>) {
83-
assertEquals(
84-
expected = expected,
85-
actual = currentTargets.size,
86-
message = "Expected $expected tab(s) but got ${currentTargets.size} instead:\n" +
87-
currentTargets.joinToString("\n"),
88-
)
89-
}
9061
}

0 commit comments

Comments
 (0)