aboutsummaryrefslogtreecommitdiffstats
path: root/hv-collector-ct
diff options
context:
space:
mode:
authorFilip Krzywka <filip.krzywka@nokia.com>2018-09-21 10:14:03 +0200
committerFilip Krzywka <filip.krzywka@nokia.com>2018-09-24 08:22:29 +0200
commite880cde732b6d5b6a2fd22b2245ba7f6ff4517f3 (patch)
tree256bd77a86bf86fce96979643a9fe5fcc0318aba /hv-collector-ct
parent7333951cfec6b79a92b12e70cf679bff2f01825a (diff)
Remove end-of-transmission message from protocol
Also update protobuf files definitions to latest version. Change-Id: I0cd5d2d8deec5c787e2d3948d3d905fa672f9fea Issue-ID: DCAEGEN2-775 Signed-off-by: Filip Krzywka <filip.krzywka@nokia.com>
Diffstat (limited to 'hv-collector-ct')
-rw-r--r--hv-collector-ct/src/test/kotlin/org/onap/dcae/collectors/veshv/tests/component/VesHvSpecification.kt45
1 files changed, 0 insertions, 45 deletions
diff --git a/hv-collector-ct/src/test/kotlin/org/onap/dcae/collectors/veshv/tests/component/VesHvSpecification.kt b/hv-collector-ct/src/test/kotlin/org/onap/dcae/collectors/veshv/tests/component/VesHvSpecification.kt
index 60e10ee0..3eba9b6b 100644
--- a/hv-collector-ct/src/test/kotlin/org/onap/dcae/collectors/veshv/tests/component/VesHvSpecification.kt
+++ b/hv-collector-ct/src/test/kotlin/org/onap/dcae/collectors/veshv/tests/component/VesHvSpecification.kt
@@ -37,7 +37,6 @@ import org.onap.dcae.collectors.veshv.tests.fakes.basicConfiguration
import org.onap.dcae.collectors.veshv.tests.fakes.configurationWithDifferentRouting
import org.onap.dcae.collectors.veshv.tests.fakes.configurationWithoutRouting
import org.onap.dcae.collectors.veshv.tests.fakes.twoDomainsToOneTopicConfiguration
-import org.onap.dcae.collectors.veshv.tests.utils.endOfTransmissionWireMessage
import org.onap.dcae.collectors.veshv.tests.utils.garbageFrame
import org.onap.dcae.collectors.veshv.tests.utils.invalidWireFrame
import org.onap.dcae.collectors.veshv.tests.utils.vesMessageWithTooBigPayload
@@ -66,30 +65,6 @@ object VesHvSpecification : Spek({
.describedAs("should send all events")
.hasSize(2)
}
-
- it("should not handle messages received from client after end-of-transmission message") {
- val (sut, sink) = vesHvWithStoringSink()
- val validMessage = vesWireFrameMessage(HVMEAS)
- val anotherValidMessage = vesWireFrameMessage(HVMEAS)
- val endOfTransmissionMessage = endOfTransmissionWireMessage()
-
- val handledEvents = sut.handleConnection(sink,
- validMessage,
- endOfTransmissionMessage,
- anotherValidMessage
- )
-
- assertThat(handledEvents).hasSize(1)
- assertThat(validMessage.refCnt())
- .describedAs("first message should be released")
- .isEqualTo(0)
- assertThat(endOfTransmissionMessage.refCnt())
- .describedAs("end-of-transmission message should be released")
- .isEqualTo(0)
- assertThat(anotherValidMessage.refCnt())
- .describedAs("second (not handled) message should not be released")
- .isEqualTo(1)
- }
}
describe("Memory management") {
@@ -116,26 +91,6 @@ object VesHvSpecification : Spek({
.isEqualTo(expectedRefCnt)
}
- it("should release memory for end-of-transmission message") {
- val (sut, sink) = vesHvWithStoringSink()
- val validMessage = vesWireFrameMessage(HVMEAS)
- val endOfTransmissionMessage = endOfTransmissionWireMessage()
- val expectedRefCnt = 0
-
- val handledEvents = sut.handleConnection(sink,
- validMessage,
- endOfTransmissionMessage
- )
-
- assertThat(handledEvents).hasSize(1)
- assertThat(validMessage.refCnt())
- .describedAs("handled message should be released")
- .isEqualTo(expectedRefCnt)
- assertThat(endOfTransmissionMessage.refCnt())
- .describedAs("end-of-transmission message should be released")
- .isEqualTo(expectedRefCnt)
- }
-
it("should release memory for each message with invalid payload") {
val (sut, sink) = vesHvWithStoringSink()
val validMessage = vesWireFrameMessage(HVMEAS)