From e74f03e5bedfa6506cda07d126ea60e12b911a93 Mon Sep 17 00:00:00 2001 From: Volodymyr Babak Date: Fri, 30 Dec 2022 16:47:49 +0200 Subject: [PATCH] EdgeControllerTest - code style fixes and IDEA warning fixes --- .../server/controller/BaseEdgeControllerTest.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/application/src/test/java/org/thingsboard/server/controller/BaseEdgeControllerTest.java b/application/src/test/java/org/thingsboard/server/controller/BaseEdgeControllerTest.java index a6dde57752..3458161d7e 100644 --- a/application/src/test/java/org/thingsboard/server/controller/BaseEdgeControllerTest.java +++ b/application/src/test/java/org/thingsboard/server/controller/BaseEdgeControllerTest.java @@ -887,8 +887,8 @@ public abstract class BaseEdgeControllerTest extends AbstractControllerTest { Edge savedEdge = doPost("/api/edge", edge, Edge.class); String installInstructions = doGet("/api/edge/instructions/" + savedEdge.getId().getId().toString(), String.class); URL resource = this.getClass().getClassLoader().getResource("edge/install_instructions/docker/expected-install-instructions.md"); + Assert.assertNotNull(resource); File file = new File(resource.toURI()); - Assert.assertEquals(new String(Files.readAllBytes(file.toPath()), StandardCharsets.UTF_8), installInstructions); + Assert.assertEquals(Files.readString(file.toPath()), installInstructions); } - -} \ No newline at end of file +}