From 63e5ab8fdbfac2553c79a4c3dc03039875d581c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Nusser?= Date: Tue, 18 Feb 2020 18:02:29 +0100 Subject: Scratch the pointer returning get and instead add getType. --- test/eventsdstest.cc | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'test') diff --git a/test/eventsdstest.cc b/test/eventsdstest.cc index b9c2f0a..a293610 100644 --- a/test/eventsdstest.cc +++ b/test/eventsdstest.cc @@ -77,12 +77,10 @@ public: } DGUNIT_ASSERT(group_concat == "abcd"); - // get + // get and getType for (auto const& sample_event: events_ds.iterateOver(13)) { DGUNIT_ASSERT(events_ds.get(sample_event.id).channel == 13); - Event* event_ptr = events_ds.get(sample_event.id); - DGUNIT_ASSERT(event_ptr->type == Event::Type::SampleEvent); - DGUNIT_ASSERT(static_cast(event_ptr)->channel == 13); + DGUNIT_ASSERT(events_ds.getType(sample_event.id) == Event::Type::SampleEvent); } // remove -- cgit v1.2.3