diff --git a/src/test/java/ch/psi/daq/test/queryrest/controller/QueryRestControllerTest.java b/src/test/java/ch/psi/daq/test/queryrest/controller/QueryRestControllerTest.java index 9c667fe..e6571f0 100644 --- a/src/test/java/ch/psi/daq/test/queryrest/controller/QueryRestControllerTest.java +++ b/src/test/java/ch/psi/daq/test/queryrest/controller/QueryRestControllerTest.java @@ -52,8 +52,9 @@ public class QueryRestControllerTest extends AbstractDaqRestTest { .andExpect(MockMvcResultMatchers.status().isOk()) .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").value("BooleanScalar")) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").value("BooleanWaveform")); + .andExpect(MockMvcResultMatchers.jsonPath("$[0]").value("BoolScalar")) + .andExpect(MockMvcResultMatchers.jsonPath("$[1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[1]").value("BoolWaveform")); } @@ -61,16 +62,19 @@ public class QueryRestControllerTest extends AbstractDaqRestTest { public void testSpecificChannelSearch() throws Exception { this.mockMvc.perform( MockMvcRequestBuilders - .get(QueryRestController.CHANNELS + "/integer") + .get(QueryRestController.CHANNELS + "/int32") .contentType(MediaType.APPLICATION_JSON)) .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").value("IntegerScalar")) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").value("IntegerWaveform")) - .andExpect(MockMvcResultMatchers.jsonPath("$[2]").value("UIntegerScalar")) - .andExpect(MockMvcResultMatchers.jsonPath("$[3]").value("UIntegerWaveform")) + .andExpect(MockMvcResultMatchers.jsonPath("$[0]").value("Int32Scalar")) + .andExpect(MockMvcResultMatchers.jsonPath("$[1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[1]").value("Int32Waveform")) + .andExpect(MockMvcResultMatchers.jsonPath("$[2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[2]").value("UInt32Scalar")) + .andExpect(MockMvcResultMatchers.jsonPath("$[3]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[3]").value("UInt32Waveform")) .andExpect(MockMvcResultMatchers.jsonPath("$[4]").doesNotExist()); } diff --git a/src/test/java/ch/psi/daq/test/queryrest/query/DummyCassandraReader.java b/src/test/java/ch/psi/daq/test/queryrest/query/DummyCassandraReader.java index 75e62dc..2eba817 100644 --- a/src/test/java/ch/psi/daq/test/queryrest/query/DummyCassandraReader.java +++ b/src/test/java/ch/psi/daq/test/queryrest/query/DummyCassandraReader.java @@ -46,29 +46,29 @@ public class DummyCassandraReader implements CassandraReader { this.channels = new String[]{ "testChannel1", "testChannel2", - "BooleanScalar", - "BooleanWaveform", - "ByteScalar", - "ByteWaveform", - "DoubleScalar", - "DoubleWaveform", - "FloatScalar", - "FloatWaveform", - "IntegerScalar", - "IntegerWaveform", - "LongScalar", - "LongWaveform", - "ShortScalar", - "ShortWaveform", - "StringScalar", - "UByteScalar", - "UByteWaveform", - "UIntegerScalar", - "UIntegerWaveform", - "ULongScalar", - "ULongWaveform", - "UShortScalar", - "UShortWaveform"}; + "BoolScalar", + "BoolWaveform", + "Int8Scalar", + "Int8Waveform", + "UInt8Scalar", + "UInt8Waveform", + "Int16Scalar", + "Int16Waveform", + "UInt16Scalar", + "UInt16Waveform", + "Int32Scalar", + "Int32Waveform", + "UInt32Scalar", + "UInt32Waveform", + "Int64Scalar", + "Int64Waveform", + "UInt64Scalar", + "UInt64Waveform", + "Float32Scalar", + "Float32Waveform", + "Float64Scalar", + "Float64Waveform", + "StringScalar"}; } /** * @{inheritDoc}