X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Ftest%2Fkotlin%2Fnet%2Fpterodactylus%2Fsone%2Ffreenet%2Fwot%2FWebOfTrustConnectorTest.kt;h=18e9ae9528cf8e428b1c9ebf2d8f1ae0a7101e3d;hp=35a5ffb0ffbc9495fe309b36be5bb2b2b0ae3f43;hb=efb51964999f24c2566946aa5c789e9dd3ff5ade;hpb=6d9add74f45486ca976c63180cf1c8296a67e66e diff --git a/src/test/kotlin/net/pterodactylus/sone/freenet/wot/WebOfTrustConnectorTest.kt b/src/test/kotlin/net/pterodactylus/sone/freenet/wot/WebOfTrustConnectorTest.kt index 35a5ffb..18e9ae9 100644 --- a/src/test/kotlin/net/pterodactylus/sone/freenet/wot/WebOfTrustConnectorTest.kt +++ b/src/test/kotlin/net/pterodactylus/sone/freenet/wot/WebOfTrustConnectorTest.kt @@ -167,6 +167,18 @@ class WebOfTrustConnectorTest { .connect { addContext(ownIdentity, "TestContext") } } + @Test + fun `removing a context sends the correct own identity id`() { + createPluginConnector("RemoveContext", hasField("Identity", equalTo(ownIdentity.id))) + .connect { removeContext(ownIdentity, "TestContext") } + } + + @Test + fun `removing a context sends the correct context`() { + createPluginConnector("RemoveContext", hasField("Context", equalTo("TestContext"))) + .connect { removeContext(ownIdentity, "TestContext") } + } + } private fun PluginConnector.connect(block: WebOfTrustConnector.() -> R) =