From 9614de67228501ca122abbba5db7874632a82ccc Mon Sep 17 00:00:00 2001 From: rschoene <rene.schoene@tu-dresden.de> Date: Fri, 5 Jun 2020 16:44:00 +0200 Subject: [PATCH] Added Read1Write2Test, and AbstractMqttTest. - all tests have fail-fast-behaviour if mqtt broker is not connected - added some documentation on how to create new test cases - Base: Fixed logging of writes to output actual values of terminal and topic --- src/main/jastadd/backend/Generation.jadd | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/jastadd/backend/Generation.jadd b/src/main/jastadd/backend/Generation.jadd index 82c1ae0..7e1f988 100644 --- a/src/main/jastadd/backend/Generation.jadd +++ b/src/main/jastadd/backend/Generation.jadd @@ -208,7 +208,9 @@ aspect AspectGeneration { .append(writeMethod()).append("() {\n"); if (loggingEnabledForWrites) { sb.append(ind(2)).append("System.out.println(\"[Write] ").append(getToken().getName()) - .append(" = \" + ").append(lastValue()).append(" + \" -> ").append(writeTopic()).append("\");\n"); + .append(" = \" + ") + .append("get").append(getToken().getName()).append("() + \" -> \" + ") + .append(writeTopic()).append(");\n"); } // _mqttUpdater().publish(${writeTopic()}, ${lastValue()}); sb.append(ind(2)).append(mqttUpdaterAttribute()).append("().publish(") -- GitLab