From ebac00d6788461e36d64f638293db0cb28c2302c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fabian=20M=C3=A4rki?= Date: Tue, 15 Nov 2016 10:04:29 +0100 Subject: [PATCH] Change in JSON table format. --- .../json/JSONResponseStreamWriter.java | 2 +- .../json/JSONTableResponseStreamWriter.java | 3 + .../QueryRestControllerJsonTableTest.java | 2552 ++++++++--------- 3 files changed, 1280 insertions(+), 1277 deletions(-) diff --git a/src/main/java/ch/psi/daq/queryrest/response/json/JSONResponseStreamWriter.java b/src/main/java/ch/psi/daq/queryrest/response/json/JSONResponseStreamWriter.java index 3952e02..2533ea5 100644 --- a/src/main/java/ch/psi/daq/queryrest/response/json/JSONResponseStreamWriter.java +++ b/src/main/java/ch/psi/daq/queryrest/response/json/JSONResponseStreamWriter.java @@ -38,7 +38,7 @@ import ch.psi.daq.queryrest.response.ResponseStreamWriter; */ public class JSONResponseStreamWriter implements ResponseStreamWriter { - private static final String DATA_RESP_FIELD = "data"; + public static final String DATA_RESP_FIELD = "data"; private static final Logger LOGGER = LoggerFactory.getLogger(JSONResponseStreamWriter.class); diff --git a/src/main/java/ch/psi/daq/queryrest/response/json/JSONTableResponseStreamWriter.java b/src/main/java/ch/psi/daq/queryrest/response/json/JSONTableResponseStreamWriter.java index 71eabe3..9970759 100644 --- a/src/main/java/ch/psi/daq/queryrest/response/json/JSONTableResponseStreamWriter.java +++ b/src/main/java/ch/psi/daq/queryrest/response/json/JSONTableResponseStreamWriter.java @@ -170,7 +170,10 @@ public class JSONTableResponseStreamWriter implements ResponseStreamWriter { Iterator> streamsMatchIter = streamMatcher.iterator(); try { + generator.writeStartObject(); + generator.writeFieldName(JSONResponseStreamWriter.DATA_RESP_FIELD); writer.writeValue(generator, streamsMatchIter); + generator.writeEndObject(); } catch (Exception e) { LOGGER.error("Exception while writing json for '{}'", daqQuery.getChannels(), e); exception.compareAndSet(null, e); diff --git a/src/test/java/ch/psi/daq/test/queryrest/controller/QueryRestControllerJsonTableTest.java b/src/test/java/ch/psi/daq/test/queryrest/controller/QueryRestControllerJsonTableTest.java index bc3ae2c..f340047 100644 --- a/src/test/java/ch/psi/daq/test/queryrest/controller/QueryRestControllerJsonTableTest.java +++ b/src/test/java/ch/psi/daq/test/queryrest/controller/QueryRestControllerJsonTableTest.java @@ -80,56 +80,56 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalMillis").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].iocSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalMillis").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].iocSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].iocMillis").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].iocMillis").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalMillis").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].iocSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalMillis").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].iocSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].iocMillis").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].iocMillis").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalMillis").value(1010)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].iocSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalMillis").value(1010)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].iocSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].iocMillis").value(1010)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].iocMillis").value(1010)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalMillis").value(1010)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].iocSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalMillis").value(1010)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].iocSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].iocMillis").value(1010)); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].iocMillis").value(1010)); } @Test @@ -157,56 +157,56 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalMillis").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].iocSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalMillis").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].iocSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].iocMillis").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].iocMillis").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalMillis").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].iocSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalMillis").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].iocSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].iocMillis").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].iocMillis").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalMillis").value(1010)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].iocSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalMillis").value(1010)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].iocSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].iocMillis").value(1010)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].iocMillis").value(1010)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalMillis").value(1010)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].iocSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalMillis").value(1010)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].iocSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].iocMillis").value(1010)); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].iocMillis").value(1010)); } @Test @@ -234,36 +234,36 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalMillis").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].iocSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalMillis").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].iocSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].iocMillis").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].iocMillis").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalMillis").value(1010)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].iocSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalMillis").value(1010)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].iocSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].iocMillis").value(1010)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].iocMillis").value(1010)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").doesNotExist()); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").doesNotExist()); } @Test @@ -289,36 +289,36 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].eventCount").value(50)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].eventCount").value(50)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].eventCount").value(50)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].eventCount").value(50)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(150)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].eventCount").value(50)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(150)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].eventCount").value(50)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(150)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].eventCount").value(50)); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(150)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].eventCount").value(50)); } @Test @@ -342,39 +342,39 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_ARCHIVERAPPLIANCE.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_ARCHIVERAPPLIANCE.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_ARCHIVERAPPLIANCE.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_ARCHIVERAPPLIANCE.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))); } @@ -408,60 +408,60 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][1].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][1].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[0][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][0].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][0].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][1].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][1].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$[0].data[1][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) .andExpect(MockMvcResultMatchers.jsonPath("$[1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0][0].channel").value(testChannel3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[0][0].channel").value(testChannel3)) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1][0].channel").value(testChannel3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1][0].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[1][0].channel").value(testChannel3)) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[1][0].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$[1].data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))); } @@ -483,39 +483,39 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(200)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(200)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(2, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(200)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(200)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalSeconds").value( TestTimeUtils.getTimeStr(2, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(201)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(201)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(2, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(201)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(201)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalSeconds").value( TestTimeUtils.getTimeStr(2, 10000000))); } @@ -542,39 +542,39 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { ) .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(101)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(101)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 10000000))); } @@ -599,25 +599,25 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").doesNotExist()); - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].channel").isMap()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].channel.name").value(TEST_CHANNEL_NAMES[0])) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data").exists()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.minima").exists()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.minima.min").exists()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.minima.min.value").exists()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.minima.min.value").value(Double.valueOf(100))) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.minima.min.event").exists()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.minima.min.event.pulseId").exists()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.minima.min.event.pulseId").value(100)) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.maxima").exists()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.maxima.max").exists()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.maxima.max.value").exists()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.maxima.max.value").value(Double.valueOf(101))) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.maxima.max.event").exists()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.maxima.max.event.pulseId").exists()) - // .andExpect(MockMvcResultMatchers.jsonPath("$[0].data.maxima.max.event.pulseId").value(101)); + .andExpect(MockMvcResultMatchers.jsonPath("$.data").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").doesNotExist()); + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].channel").isMap()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].channel.name").value(TEST_CHANNEL_NAMES[0])) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data").exists()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.minima").exists()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.minima.min").exists()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.minima.min.value").exists()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.minima.min.value").value(Double.valueOf(100))) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.minima.min.event").exists()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.minima.min.event.pulseId").exists()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.minima.min.event.pulseId").value(100)) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.maxima").exists()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.maxima.max").exists()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.maxima.max.value").exists()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.maxima.max.value").value(Double.valueOf(101))) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.maxima.max.event").exists()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.maxima.max.event.pulseId").exists()) + // .andExpect(MockMvcResultMatchers.jsonPath("$.data[0].data.maxima.max.event.pulseId").value(101)); } @Test @@ -648,56 +648,56 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { ) .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value.min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value.mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value.max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value.min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value.mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value.max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value.min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value.mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value.max").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value.min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value.mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value.max").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value.min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value.mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value.max").value(109.0)); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value.min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value.mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value.max").value(109.0)); } @Test @@ -730,96 +730,96 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { ) .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema.minValue.value").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema.minValue.pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema.minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema.minValue.value").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema.minValue.pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema.minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema.minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema.maxValue.value").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema.maxValue.pulseId").value(104)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema.maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema.minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema.maxValue.value").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema.maxValue.pulseId").value(104)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema.maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 40000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema.maxValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema.maxValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value.min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value.mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value.max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema.minValue.value").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema.minValue.pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema.minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value.min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value.mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value.max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema.minValue.value").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema.minValue.pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema.minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema.minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema.maxValue.value").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema.maxValue.pulseId").value(104)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema.maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema.minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema.maxValue.value").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema.maxValue.pulseId").value(104)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema.maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 40000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema.maxValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema.maxValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value.min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value.mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value.max").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema.minValue.value").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema.minValue.pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema.minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value.min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value.mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value.max").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema.minValue.value").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema.minValue.pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema.minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema.minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema.maxValue.value").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema.maxValue.pulseId").value(109)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema.maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema.minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema.maxValue.value").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema.maxValue.pulseId").value(109)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema.maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 90000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema.maxValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema.maxValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value.min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value.mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value.max").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema.minValue.value").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema.minValue.pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema.minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value.min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value.mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value.max").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema.minValue.value").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema.minValue.pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema.minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema.minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema.maxValue.value").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema.maxValue.pulseId").value(109)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema.maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema.minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema.maxValue.value").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema.maxValue.pulseId").value(109)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema.maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 90000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema.maxValue.eventCount").value(1)); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema.maxValue.eventCount").value(1)); } @Test @@ -848,266 +848,266 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { ) .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(10, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.min").value(1000.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.mean").value(1004.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.max").value(1009.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.min").value(1000.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.mean").value(1004.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.max").value(1009.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(1000)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(1000)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalSeconds").value( TestTimeUtils.getTimeStr(10, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value.min").value(1000.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value.mean").value(1004.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value.max").value(1009.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value.min").value(1000.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value.mean").value(1004.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value.max").value(1009.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(1010)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(1010)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(10, 100000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value.min").value(1010.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value.mean").value(1014.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value.max").value(1019.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value.min").value(1010.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value.mean").value(1014.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value.max").value(1019.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(1010)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(1010)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalSeconds").value( TestTimeUtils.getTimeStr(10, 100000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value.min").value(1010.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value.mean").value(1014.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value.max").value(1019.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value.min").value(1010.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value.mean").value(1014.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value.max").value(1019.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].pulseId").value(1020)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].pulseId").value(1020)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].globalSeconds").value( TestTimeUtils.getTimeStr(10, 200000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].value.min").value(1020.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].value.mean").value(1024.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].value.max").value(1029.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].value.min").value(1020.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].value.mean").value(1024.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].value.max").value(1029.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].pulseId").value(1020)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].pulseId").value(1020)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].globalSeconds").value( TestTimeUtils.getTimeStr(10, 200000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].value.min").value(1020.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].value.mean").value(1024.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].value.max").value(1029.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].value.min").value(1020.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].value.mean").value(1024.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].value.max").value(1029.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].pulseId").value(1030)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].pulseId").value(1030)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].globalSeconds").value( TestTimeUtils.getTimeStr(10, 300000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].value.min").value(1030.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].value.mean").value(1034.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].value.max").value(1039.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].value.min").value(1030.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].value.mean").value(1034.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].value.max").value(1039.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].pulseId").value(1030)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].pulseId").value(1030)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].globalSeconds").value( TestTimeUtils.getTimeStr(10, 300000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].value.min").value(1030.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].value.mean").value(1034.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].value.max").value(1039.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].value.min").value(1030.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].value.mean").value(1034.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].value.max").value(1039.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].pulseId").value(1040)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].pulseId").value(1040)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].globalSeconds").value( TestTimeUtils.getTimeStr(10, 400000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].value.min").value(1040.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].value.mean").value(1044.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].value.max").value(1049.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].value.min").value(1040.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].value.mean").value(1044.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].value.max").value(1049.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].pulseId").value(1040)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].pulseId").value(1040)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].globalSeconds").value( TestTimeUtils.getTimeStr(10, 400000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].value.min").value(1040.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].value.mean").value(1044.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].value.max").value(1049.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].value.min").value(1040.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].value.mean").value(1044.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].value.max").value(1049.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].pulseId").value(1050)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].pulseId").value(1050)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].globalSeconds").value( TestTimeUtils.getTimeStr(10, 500000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].value.min").value(1050.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].value.mean").value(1054.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].value.max").value(1059.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].value.min").value(1050.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].value.mean").value(1054.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].value.max").value(1059.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].pulseId").value(1050)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].pulseId").value(1050)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].globalSeconds").value( TestTimeUtils.getTimeStr(10, 500000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value.min").value(1050.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value.mean").value(1054.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value.max").value(1059.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value.min").value(1050.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value.mean").value(1054.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value.max").value(1059.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].pulseId").value(1060)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].pulseId").value(1060)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].globalSeconds").value( TestTimeUtils.getTimeStr(10, 600000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value.min").value(1060.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value.mean").value(1064.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value.max").value(1069.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value.min").value(1060.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value.mean").value(1064.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value.max").value(1069.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1].pulseId").value(1060)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1].pulseId").value(1060)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1].globalSeconds").value( TestTimeUtils.getTimeStr(10, 600000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1].value.min").value(1060.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1].value.mean").value(1064.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1].value.max").value(1069.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1].value.min").value(1060.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1].value.mean").value(1064.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1].value.max").value(1069.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[7]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][0].pulseId").value(1070)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][0].pulseId").value(1070)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][0].globalSeconds").value( TestTimeUtils.getTimeStr(10, 700000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][0].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][0].value.min").value(1070.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][0].value.mean").value(1074.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][0].value.max").value(1079.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][0].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][0].value.min").value(1070.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][0].value.mean").value(1074.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][0].value.max").value(1079.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][1].pulseId").value(1070)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][1].pulseId").value(1070)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][1].globalSeconds").value( TestTimeUtils.getTimeStr(10, 700000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][1].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][1].value.min").value(1070.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][1].value.mean").value(1074.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[7][1].value.max").value(1079.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][1].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][1].value.min").value(1070.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][1].value.mean").value(1074.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7][1].value.max").value(1079.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[8]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][0].pulseId").value(1080)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][0].pulseId").value(1080)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][0].globalSeconds").value( TestTimeUtils.getTimeStr(10, 800000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][0].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][0].value.min").value(1080.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][0].value.mean").value(1084.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][0].value.max").value(1089.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][0].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][0].value.min").value(1080.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][0].value.mean").value(1084.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][0].value.max").value(1089.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][1].pulseId").value(1080)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][1].pulseId").value(1080)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][1].globalSeconds").value( TestTimeUtils.getTimeStr(10, 800000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][1].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][1].value.min").value(1080.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][1].value.mean").value(1084.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[8][1].value.max").value(1089.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][1].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][1].value.min").value(1080.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][1].value.mean").value(1084.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[8][1].value.max").value(1089.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[9]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][0].channel").value(TEST_CHANNEL_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][0].pulseId").value(1090)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][0].channel").value(TEST_CHANNEL_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][0].pulseId").value(1090)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][0].globalSeconds").value( TestTimeUtils.getTimeStr(10, 900000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][0].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][0].value.min").value(1090.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][0].value.mean").value(1094.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][0].value.max").value(1099.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][0].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][0].value.min").value(1090.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][0].value.mean").value(1094.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][0].value.max").value(1099.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][1].channel").value(TEST_CHANNEL_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][1].pulseId").value(1090)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][1].channel").value(TEST_CHANNEL_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][1].pulseId").value(1090)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][1].globalSeconds").value( TestTimeUtils.getTimeStr(10, 900000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][1].eventCount").value(10)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][1].value.min").value(1090.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][1].value.mean").value(1094.5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[9][1].value.max").value(1099.0)); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][1].eventCount").value(10)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][1].value.min").value(1090.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][1].value.mean").value(1094.5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[9][1].value.max").value(1099.0)); } @Test @@ -1140,68 +1140,68 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { ) .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_WAVEFORM_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_WAVEFORM_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[0].min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[0].mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[0].max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[1].min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[1].mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[1].max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[0].min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[0].mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[0].max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[1].min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[1].mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[1].max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(TEST_CHANNEL_WAVEFORM_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(TEST_CHANNEL_WAVEFORM_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[0].min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[0].mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[0].max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[1].min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[1].mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[1].max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[0].min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[0].mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[0].max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[1].min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[1].mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[1].max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_WAVEFORM_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_WAVEFORM_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[0].min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[0].mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[0].max").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[1].min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[1].mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[1].max").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[0].min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[0].mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[0].max").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[1].min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[1].mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[1].max").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(TEST_CHANNEL_WAVEFORM_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(TEST_CHANNEL_WAVEFORM_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[0].min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[0].mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[0].max").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[1].min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[1].mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[1].max").value(109.0)); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[0].min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[0].mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[0].max").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[1].min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[1].mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[1].max").value(109.0)); } @Test @@ -1235,152 +1235,152 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { ) .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(TEST_CHANNEL_WAVEFORM_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(TEST_CHANNEL_WAVEFORM_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[0].min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[0].mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[0].max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[1].min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[1].mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[1].max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[0].minValue.value").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[0].minValue.pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[0].minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[0].min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[0].mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[0].max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[1].min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[1].mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[1].max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[0].minValue.value").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[0].minValue.pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[0].minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[0].minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[0].maxValue.value").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[0].maxValue.pulseId").value(104)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[0].maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[0].minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[0].maxValue.value").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[0].maxValue.pulseId").value(104)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[0].maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 40000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[0].maxValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[1].minValue.value").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[1].minValue.pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[1].minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[0].maxValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[1].minValue.value").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[1].minValue.pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[1].minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[1].minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[1].maxValue.value").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[1].maxValue.pulseId").value(104)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[1].maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[1].minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[1].maxValue.value").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[1].maxValue.pulseId").value(104)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[1].maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 40000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].extrema[1].maxValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].extrema[1].maxValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(TEST_CHANNEL_WAVEFORM_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(TEST_CHANNEL_WAVEFORM_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[0].min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[0].mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[0].max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[1].min").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[1].mean").value(102.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[1].max").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[0].minValue.value").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[0].minValue.pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[0].minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[0].min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[0].mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[0].max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[1].min").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[1].mean").value(102.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[1].max").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[0].minValue.value").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[0].minValue.pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[0].minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[0].minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[0].maxValue.value").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[0].maxValue.pulseId").value(104)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[0].maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[0].minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[0].maxValue.value").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[0].maxValue.pulseId").value(104)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[0].maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 40000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[0].maxValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[1].minValue.value").value(100.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[1].minValue.pulseId").value(100)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[1].minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[0].maxValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[1].minValue.value").value(100.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[1].minValue.pulseId").value(100)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[1].minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 0))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[1].minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[1].maxValue.value").value(104.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[1].maxValue.pulseId").value(104)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[1].maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[1].minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[1].maxValue.value").value(104.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[1].maxValue.pulseId").value(104)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[1].maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 40000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].extrema[1].maxValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].extrema[1].maxValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(TEST_CHANNEL_WAVEFORM_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(TEST_CHANNEL_WAVEFORM_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[0].min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[0].mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[0].max").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[1].min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[1].mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[1].max").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[0].minValue.value").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[0].minValue.pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[0].minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[0].min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[0].mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[0].max").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[1].min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[1].mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[1].max").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[0].minValue.value").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[0].minValue.pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[0].minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[0].minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[0].maxValue.value").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[0].maxValue.pulseId").value(109)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[0].maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[0].minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[0].maxValue.value").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[0].maxValue.pulseId").value(109)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[0].maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 90000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[0].maxValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[1].minValue.value").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[1].minValue.pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[1].minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[0].maxValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[1].minValue.value").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[1].minValue.pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[1].minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[1].minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[1].maxValue.value").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[1].maxValue.pulseId").value(109)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[1].maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[1].minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[1].maxValue.value").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[1].maxValue.pulseId").value(109)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[1].maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 90000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].extrema[1].maxValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].extrema[1].maxValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(TEST_CHANNEL_WAVEFORM_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(TEST_CHANNEL_WAVEFORM_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].eventCount").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value[0].min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value[0].mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value[0].max").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value[1].min").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value[1].mean").value(107.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value[1].max").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[0].minValue.value").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[0].minValue.pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[0].minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].eventCount").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value[0].min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value[0].mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value[0].max").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value[1].min").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value[1].mean").value(107.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value[1].max").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[0].minValue.value").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[0].minValue.pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[0].minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[0].minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[0].maxValue.value").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[0].maxValue.pulseId").value(109)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[0].maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[0].minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[0].maxValue.value").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[0].maxValue.pulseId").value(109)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[0].maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 90000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[0].maxValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[1].minValue.value").value(105.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[1].minValue.pulseId").value(105)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[1].minValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[0].maxValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[1].minValue.value").value(105.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[1].minValue.pulseId").value(105)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[1].minValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 50000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[1].minValue.eventCount").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[1].maxValue.value").value(109.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[1].maxValue.pulseId").value(109)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[1].maxValue.globalSeconds").value( + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[1].minValue.eventCount").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[1].maxValue.value").value(109.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[1].maxValue.pulseId").value(109)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[1].maxValue.globalSeconds").value( TestTimeUtils.getTimeStr(1, 90000000))) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].extrema[1].maxValue.eventCount").value(1)); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].extrema[1].maxValue.eventCount").value(1)); } @Test @@ -1416,29 +1416,29 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][3]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][3]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").doesNotExist()); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1]").doesNotExist()); } @@ -1475,113 +1475,113 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].pulseId").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].pulseId").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].pulseId").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].pulseId").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].pulseId").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].pulseId").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].pulseId").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].pulseId").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].pulseId").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].pulseId").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].pulseId").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].pulseId").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][3]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][3]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].pulseId").value(6)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].pulseId").value(6)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[7]").doesNotExist()); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7]").doesNotExist()); } @@ -1618,127 +1618,127 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2].pulseId").value(0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][3]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2].pulseId").value(0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][3]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][2]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][2].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][2].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][2].pulseId").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][3]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][2]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][2].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][2].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][2].pulseId").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][3]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].pulseId").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].pulseId").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][2]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][2].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][2].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][2].pulseId").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][3]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][2]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][2].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][2].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][2].pulseId").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][3]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].pulseId").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].pulseId").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][2]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][2].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][2].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][2].pulseId").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][3]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][2]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][2].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][2].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][2].pulseId").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][3]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].pulseId").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].pulseId").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][2]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][2].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][2].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][2].pulseId").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][3]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][2]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][2].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][2].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][2].pulseId").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][3]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][3]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][3]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1].pulseId").value(6)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1].pulseId").value(6)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][3]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][3]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[7]").doesNotExist()); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7]").doesNotExist()); } @@ -1781,139 +1781,139 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].eventCount").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.min").value(0.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.mean").value(0.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value.max").value(0.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].eventCount").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.min").value(0.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.mean").value(0.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value.max").value(0.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value").value(0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value").value(0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].pulseId").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].value").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].pulseId").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].value").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].pulseId").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].value").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].pulseId").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].value").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].pulseId").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].value").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].pulseId").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].value").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].pulseId").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].value").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].pulseId").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].value").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].pulseId").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].value").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].pulseId").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].value").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].pulseId").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].value").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].pulseId").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].value").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].value").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].value").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].eventCount").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value.min").value(5.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value.mean").value(5.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value.max").value(5.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].eventCount").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value.min").value(5.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value.mean").value(5.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value.max").value(5.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].value").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][3]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].value").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][3]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].pulseId").value(6)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].eventCount").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value.min").value(6.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value.mean").value(6.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value.max").value(6.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].pulseId").value(6)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].eventCount").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value.min").value(6.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value.mean").value(6.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value.max").value(6.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[7]").doesNotExist()); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7]").doesNotExist()); } @@ -1956,176 +1956,176 @@ public class QueryRestControllerJsonTableTest extends AbstractDaqRestTest { .andDo(MockMvcResultHandlers.print()) .andExpect(MockMvcResultMatchers.status().isOk()) - .andExpect(MockMvcResultMatchers.jsonPath("$").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].pulseId").value(0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].eventCount").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[0].min").value(0.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[0].mean").value(0.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[0].max").value(0.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[1].min").value(0.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[1].mean").value(0.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][0].value[1].max").value(0.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].pulseId").value(0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].eventCount").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[0].min").value(0.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[0].mean").value(0.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[0].max").value(0.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[1].min").value(0.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[1].mean").value(0.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][0].value[1].max").value(0.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].pulseId").value(0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[0]").value(0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][1].value[1]").value(0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[0][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].pulseId").value(0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[0]").value(0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][1].value[1]").value(0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[0][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].pulseId").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[0]").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][0].value[1]").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].pulseId").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[0]").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][0].value[1]").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].pulseId").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value[0]").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][1].value[1]").value(1)) - .andExpect(MockMvcResultMatchers.jsonPath("$[1][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].pulseId").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value[0]").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][1].value[1]").value(1)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[1][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].pulseId").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].value[0]").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][0].value[1]").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].pulseId").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].value[0]").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][0].value[1]").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].pulseId").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].value[0]").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][1].value[1]").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[2][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].pulseId").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].value[0]").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][1].value[1]").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[2][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].pulseId").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].value[0]").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][0].value[1]").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].pulseId").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].value[0]").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][0].value[1]").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].pulseId").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].value[0]").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][1].value[1]").value(3)) - .andExpect(MockMvcResultMatchers.jsonPath("$[3][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].pulseId").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].value[0]").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][1].value[1]").value(3)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[3][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].pulseId").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].value[0]").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][0].value[1]").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].pulseId").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].value[0]").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][0].value[1]").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].pulseId").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].value[0]").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][1].value[1]").value(4)) - .andExpect(MockMvcResultMatchers.jsonPath("$[4][2]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].pulseId").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].value[0]").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][1].value[1]").value(4)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[4][2]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].channel").value(channel_01)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].value[0]").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][0].value[1]").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].channel").value(channel_01)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].value[0]").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][0].value[1]").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].eventCount").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value[0].min").value(5.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value[0].mean").value(5.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value[0].max").value(5.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value[1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value[1].min").value(5.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value[1].mean").value(5.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][1].value[1].max").value(5.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].eventCount").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value[0].min").value(5.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value[0].mean").value(5.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value[0].max").value(5.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value[1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value[1].min").value(5.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value[1].mean").value(5.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][1].value[1].max").value(5.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].channel").value(channel_03)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].pulseId").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].value[0]").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][2].value[1]").value(5)) - .andExpect(MockMvcResultMatchers.jsonPath("$[5][3]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].channel").value(channel_03)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].pulseId").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].value[0]").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][2].value[1]").value(5)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[5][3]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6]").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0]").isMap()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].channel").value(channel_02)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].backend").value(Backend.SF_DATABUFFER.getKey())) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].pulseId").value(6)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].eventCount").value(2)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value").isArray()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value[0]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value[0].min").value(6.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value[0].mean").value(6.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value[0].max").value(6.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value[1]").exists()) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value[1].min").value(6.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value[1].mean").value(6.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][0].value[1].max").value(6.0)) - .andExpect(MockMvcResultMatchers.jsonPath("$[6][1]").doesNotExist()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6]").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0]").isMap()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].channel").value(channel_02)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].backend").value(Backend.SF_DATABUFFER.getKey())) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].pulseId").value(6)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].eventCount").value(2)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value").isArray()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value[0]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value[0].min").value(6.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value[0].mean").value(6.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value[0].max").value(6.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value[1]").exists()) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value[1].min").value(6.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value[1].mean").value(6.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][0].value[1].max").value(6.0)) + .andExpect(MockMvcResultMatchers.jsonPath("$.data[6][1]").doesNotExist()) - .andExpect(MockMvcResultMatchers.jsonPath("$[7]").doesNotExist()); + .andExpect(MockMvcResultMatchers.jsonPath("$.data[7]").doesNotExist()); } }