Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logging fo debug images swapped #14

Merged
merged 1 commit into from
Jan 20, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -415,13 +415,13 @@ public void debugSymbolsSmokeGDB(TestInfo testInfo) throws IOException, Interrup
esvc.submit(reader);

try (BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(process.getOutputStream()))) {
Logs.appendln(report, appDir.getAbsolutePath());
Logs.appendlnSection(report, String.join(" ", processBuilder.command()));
Logs.appendln(report, stringBuffer.toString());
assertTrue(waitForBufferToMatch(stringBuffer,
Pattern.compile(".*Reading symbols from \\./target/debug-symbols-smoke\\.\\.\\.done\\..*", Pattern.DOTALL),
3000, 500, TimeUnit.MILLISECONDS),
"GDB session did not start well. Check the names, paths... Content was: " + stringBuffer.toString());
Logs.appendln(report, appDir.getAbsolutePath());
Logs.appendlnSection(report, String.join(" ", processBuilder.command()));
Logs.appendln(report, stringBuffer.toString());

carryOutGDBSession(stringBuffer, GDBSession.DEBUG_SYMBOLS_SMOKE, esvc, writer, report);

Expand Down Expand Up @@ -479,13 +479,13 @@ public void debugSymbolsQuarkus(TestInfo testInfo) throws IOException, Interrupt
esvc.submit(reader);

try (BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(process.getOutputStream()))) {
Logs.appendln(report, appDir.getAbsolutePath());
Logs.appendlnSection(report, String.join(" ", processBuilder.command()));
Logs.appendln(report, stringBuffer.toString());
assertTrue(waitForBufferToMatch(stringBuffer,
Pattern.compile(".*Reading symbols from.*quarkus-runner.debug.*done.*", Pattern.DOTALL),
3000, 500, TimeUnit.MILLISECONDS),
"GDB session did not start well. Check the names, paths... Content was: " + stringBuffer.toString());
Logs.appendln(report, appDir.getAbsolutePath());
Logs.appendlnSection(report, String.join(" ", processBuilder.command()));
Logs.appendln(report, stringBuffer.toString());

writer.write("set confirm off\n");
writer.flush();
Expand Down Expand Up @@ -557,13 +557,13 @@ public void debugSymbolsQuarkusContainer(TestInfo testInfo) throws IOException,
esvc.submit(reader);

try (BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(gdbProcess.getOutputStream()))) {
Logs.appendln(report, appDir.getAbsolutePath());
Logs.appendlnSection(report, String.join(" ", processBuilder.command()));
Logs.appendln(report, stringBuffer.toString());
assertTrue(waitForBufferToMatch(stringBuffer,
Pattern.compile(".*Reading symbols from.*/work/quarkus-runner.debug.*done.*", Pattern.DOTALL),
3000, 500, TimeUnit.MILLISECONDS),
"GDB session did not start well. Check the names, paths... Content was: " + stringBuffer.toString());
Logs.appendln(report, appDir.getAbsolutePath());
Logs.appendlnSection(report, String.join(" ", processBuilder.command()));
Logs.appendln(report, stringBuffer.toString());

writer.write("set confirm off\n");
writer.flush();
Expand Down