From a4dfdb3165cb98c50d7157cb8216b68a8823121f Mon Sep 17 00:00:00 2001 From: rusefillc Date: Thu, 7 Jul 2022 23:16:39 -0400 Subject: [PATCH] debug is set to idle mode, but none of the debug fields show anything #4335 current state is a bit broken --- .../test/java/com/rusefi/test/OutputsTest.java | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/java_tools/configuration_definition/src/test/java/com/rusefi/test/OutputsTest.java b/java_tools/configuration_definition/src/test/java/com/rusefi/test/OutputsTest.java index 07da6604ed..5016406d5c 100644 --- a/java_tools/configuration_definition/src/test/java/com/rusefi/test/OutputsTest.java +++ b/java_tools/configuration_definition/src/test/java/com/rusefi/test/OutputsTest.java @@ -118,6 +118,24 @@ public class OutputsTest { } + @Test + public void generateDataLogMultiLineCommentWithQuotes() throws IOException { + String test = "struct total\n" + + "\tuint16_t autoscale baseFuel;@@GAUGE_NAME_FUEL_BASE@@\\nThis is the raw value we take from the fuel map or base fuel algorithm, before the corrections;\"mg\",1, 0, 0, 0, 0\n" + + "\tuint16_t autoscale baseFuel2;\"line1\\nline2\";\"mg\",1, 0, 0, 0, 0\n" + + "end_struct\n"; + ReaderState state = new ReaderState(); + state.variableRegistry.register("GAUGE_NAME_FUEL_BASE", "hello"); + + DataLogConsumer dataLogConsumer = new DataLogConsumer(null); + state.readBufferedReader(test, (dataLogConsumer)); + assertEquals( + "entry = baseFuel, \"hello\", int, \"%d\"\n" + + "entry = baseFuel2, \"line1, int, \"%d\"\n" + , dataLogConsumer.getContent()); + + } + @Test public void generateGetOutputs() throws IOException { String test = "struct_no_prefix ts_outputs_s\n" +