From d0ae6a3a866f951b3f478a3fae14c624b21967b4 Mon Sep 17 00:00:00 2001 From: Vadzim Hushchanskou Date: Thu, 8 Feb 2024 18:23:03 +0300 Subject: [PATCH] Fix tests --- .../reportportal/cucumber/EmbeddingTest.java | 28 +++++++++---------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/test/java/com/epam/reportportal/cucumber/EmbeddingTest.java b/src/test/java/com/epam/reportportal/cucumber/EmbeddingTest.java index 0241097..4d84d95 100644 --- a/src/test/java/com/epam/reportportal/cucumber/EmbeddingTest.java +++ b/src/test/java/com/epam/reportportal/cucumber/EmbeddingTest.java @@ -54,42 +54,42 @@ public class EmbeddingTest { @CucumberOptions(features = "src/test/resources/features/embedding/ImageEmbeddingFeature.feature", glue = { "com.epam.reportportal.cucumber.integration.embed.image" }, plugin = { "pretty", "com.epam.reportportal.cucumber.integration.TestStepReporter" }) - public static class ImageStepReporter extends AbstractTestNGCucumberTests { + public static class ImageStepReporterTest extends AbstractTestNGCucumberTests { } @CucumberOptions(features = "src/test/resources/features/embedding/TextEmbeddingFeature.feature", glue = { "com.epam.reportportal.cucumber.integration.embed.text" }, plugin = { "pretty", "com.epam.reportportal.cucumber.integration.TestStepReporter" }) - public static class TextStepReporter extends AbstractTestNGCucumberTests { + public static class TextStepReporterTest extends AbstractTestNGCucumberTests { } @CucumberOptions(features = "src/test/resources/features/embedding/PdfEmbeddingFeature.feature", glue = { "com.epam.reportportal.cucumber.integration.embed.pdf" }, plugin = { "pretty", "com.epam.reportportal.cucumber.integration.TestStepReporter" }) - public static class PdfStepReporter extends AbstractTestNGCucumberTests { + public static class PdfStepReporterTest extends AbstractTestNGCucumberTests { } @CucumberOptions(features = "src/test/resources/features/embedding/ArchiveEmbeddingFeature.feature", glue = { "com.epam.reportportal.cucumber.integration.embed.zip" }, plugin = { "pretty", "com.epam.reportportal.cucumber.integration.TestStepReporter" }) - public static class ZipStepReporter extends AbstractTestNGCucumberTests { + public static class ZipStepReporterTest extends AbstractTestNGCucumberTests { } @CucumberOptions(features = "src/test/resources/features/embedding/EmbedImageWithoutName.feature", glue = { "com.epam.reportportal.cucumber.integration.embed.image" }, plugin = { "pretty", "com.epam.reportportal.cucumber.integration.TestStepReporter" }) - public static class ImageNoNameStepReporter extends AbstractTestNGCucumberTests { + public static class ImageNoNameStepReporterTest extends AbstractTestNGCucumberTests { } @CucumberOptions(features = "src/test/resources/features/embedding/EmbedImageWithEmptyName.feature", glue = { "com.epam.reportportal.cucumber.integration.embed.image" }, plugin = { "pretty", "com.epam.reportportal.cucumber.integration.TestStepReporter" }) - public static class ImageEmptyNameStepReporter extends AbstractTestNGCucumberTests { + public static class ImageEmptyNameStepReporterTest extends AbstractTestNGCucumberTests { } @@ -132,7 +132,7 @@ public void setup() { @Test public void verify_image_embedding() { - TestUtils.runTests(ImageStepReporter.class); + TestUtils.runTests(ImageStepReporterTest.class); ArgumentCaptor> logCaptor = ArgumentCaptor.forClass(List.class); verify(client, atLeastOnce()).log(logCaptor.capture()); @@ -147,7 +147,7 @@ public void verify_image_embedding() { @Test public void verify_text_embedding() { - TestUtils.runTests(TextStepReporter.class); + TestUtils.runTests(TextStepReporterTest.class); ArgumentCaptor> logCaptor = ArgumentCaptor.forClass(List.class); verify(client, atLeastOnce()).log(logCaptor.capture()); @@ -161,7 +161,7 @@ public void verify_text_embedding() { @Test public void verify_pfd_embedding() { - TestUtils.runTests(PdfStepReporter.class); + TestUtils.runTests(PdfStepReporterTest.class); ArgumentCaptor> logCaptor = ArgumentCaptor.forClass(List.class); verify(client, atLeastOnce()).log(logCaptor.capture()); @@ -169,12 +169,12 @@ public void verify_pfd_embedding() { List types = getTypes(logCaptor, logs); assertThat(types, hasSize(3)); - assertThat(types, containsInAnyOrder("application/pdf", "image/png", "application/octet-stream")); + assertThat(types, containsInAnyOrder("application/pdf", "image/png", "application/pdf")); } @Test public void verify_archive_embedding() { - TestUtils.runTests(ZipStepReporter.class); + TestUtils.runTests(ZipStepReporterTest.class); ArgumentCaptor> logCaptor = ArgumentCaptor.forClass(List.class); verify(client, atLeastOnce()).log(logCaptor.capture()); @@ -182,12 +182,12 @@ public void verify_archive_embedding() { List types = getTypes(logCaptor, logs); assertThat(types, hasSize(3)); - assertThat(types, containsInAnyOrder("application/zip", "image/png", "application/octet-stream")); + assertThat(types, containsInAnyOrder("application/zip", "image/png", "application/zip")); } @Test public void verify_image_no_name_embedding() { - TestUtils.runTests(ImageNoNameStepReporter.class); + TestUtils.runTests(ImageNoNameStepReporterTest.class); ArgumentCaptor> logCaptor = ArgumentCaptor.forClass(List.class); verify(client, atLeastOnce()).log(logCaptor.capture()); @@ -202,7 +202,7 @@ public void verify_image_no_name_embedding() { @Test public void verify_image_empty_name_embedding() { - TestUtils.runTests(ImageEmptyNameStepReporter.class); + TestUtils.runTests(ImageEmptyNameStepReporterTest.class); ArgumentCaptor> logCaptor = ArgumentCaptor.forClass(List.class); verify(client, atLeastOnce()).log(logCaptor.capture());