diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 2ac9b444..4cfe2242 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -248,7 +248,7 @@ jobs: path: ~/.m2 key: ${{runner.os}}-m2 - name: Create settings file - uses: whelk-io/maven-settings-xml-action@v20 + uses: whelk-io/maven-settings-xml-action@v21 with: profiles: '[{"id": "gpg", "properties": { "gpg.keyname": "${{secrets.GPG_KEYNAME_ID}}", "gpg.passphrase": "${{secrets.GPG_PASSPHRASE}}" }}]' servers: '[{"id": "ossrh", "username": "${{secrets.DEPLOY_PACKAGE_USERNAME}}", "password": "${{secrets.DEPLOY_PACKAGE_PASSWORD}}"}]' diff --git a/openmaqs-selenium/src/test/java/io/github/openmaqs/selenium/UIFindUnitTest.java b/openmaqs-selenium/src/test/java/io/github/openmaqs/selenium/UIFindUnitTest.java index 318fdcb1..4d6a0eb6 100644 --- a/openmaqs-selenium/src/test/java/io/github/openmaqs/selenium/UIFindUnitTest.java +++ b/openmaqs-selenium/src/test/java/io/github/openmaqs/selenium/UIFindUnitTest.java @@ -42,7 +42,6 @@ private void setUp() { */ @Test(groups = TestCategories.SELENIUM) public void findElementFound() { -// UIFind find = setUp(); WebElement element = find.findElement(automationPageModel.automationNamesLabel); Assert.assertEquals(element.getText(),"Names"); } @@ -53,7 +52,6 @@ public void findElementFound() { */ @Test(groups = TestCategories.SELENIUM) public void findElementNotFound() { -// UIFind find = setUp(); Assert.assertNull(find.findElement(automationPageModel.notInPage, false)); } @@ -62,7 +60,6 @@ public void findElementNotFound() { */ @Test(groups = TestCategories.SELENIUM, expectedExceptions = NotFoundException.class) public void findElementCatchException() { -// UIFind find = setUp(); find.findElement(automationPageModel.notInPage, true); } @@ -71,7 +68,6 @@ public void findElementCatchException() { */ @Test(groups = TestCategories.SELENIUM) public void findElementsFound() { -// UIFind find = setUp(); List list = find.findElements(automationPageModel.dropdownToggleClassSelector); Assert.assertEquals(list.size(),2, "There are 2 elements with dropdown classes"); @@ -89,7 +85,6 @@ public void findElementsFound() { */ @Test(groups = TestCategories.SELENIUM) public void findElementsNotFound() { -// UIFind find = setUp(); List list = find.findElements(automationPageModel.notInPage, false); Assert.assertEquals(list.size(), 0); } @@ -99,7 +94,6 @@ public void findElementsNotFound() { */ @Test(groups = TestCategories.SELENIUM) public void findElementsNotFoundThrowException() { -// UIFind find = setUp(); List elements = find.findElements(automationPageModel.notInPage, false); Assert.assertEquals(elements.size(), 0); } @@ -109,7 +103,6 @@ public void findElementsNotFoundThrowException() { */ @Test(groups = TestCategories.SELENIUM) public void findElementWithTextElementNotFound() { -// UIFind find = setUp(); Assert.assertNull(find.findElementWithText(automationPageModel.notInPage, "notInPage", false), "Element was not found"); } @@ -120,9 +113,8 @@ public void findElementWithTextElementNotFound() { */ @Test(groups = TestCategories.SELENIUM) public void findElementWithText() { -// UIFind find = setUp(); - String text = find.findElement(automationPageModel.automationShowDialog1).getText(); - Assert.assertNotNull(find.findElementWithText(automationPageModel.automationShowDialog1, text), + String text = find.findElement(automationPageModel.automationPageHeader).getText(); + Assert.assertNotNull(find.findElementWithText(automationPageModel.automationPageHeader, text), "Element was not found"); } @@ -143,7 +135,6 @@ public void findElementWithTextNotFound() { */ @Test(groups = TestCategories.SELENIUM) public void findIndexOfElementWithText() { -// UIFind find = setUp(); Assert.assertEquals(find.findIndexOfElementWithText(automationPageModel.flowerTable, "Red"), 3); } @@ -153,7 +144,6 @@ public void findIndexOfElementWithText() { */ @Test(groups = TestCategories.SELENIUM) public void findIndexOfElementWithTextNotFound() { -// UIFind find = setUp(); Assert.assertEquals(find.findIndexOfElementWithText(automationPageModel.flowerTable, "#notfound", false), -1); } @@ -164,7 +154,6 @@ public void findIndexOfElementWithTextNotFound() { */ @Test(groups = TestCategories.SELENIUM) public void findIndexOfElementWithTextWithNotFoundElement() { -// UIFind find = setUp(); Assert.assertEquals(find.findIndexOfElementWithText(automationPageModel.notInPage, "#notfound", false), -1); } @@ -175,7 +164,6 @@ public void findIndexOfElementWithTextWithNotFoundElement() { */ @Test(groups = TestCategories.SELENIUM) public void findIndexOfElementInCollection() { -// UIFind find = setUp(); Assert.assertEquals(find.findIndexOfElementWithText( find.findElements(automationPageModel.flowerTable), "10 in"), 0); } @@ -185,7 +173,6 @@ public void findIndexOfElementInCollection() { */ @Test(groups = TestCategories.SELENIUM, expectedExceptions = NotFoundException.class) public void findIndexOfElementInCollectionThrowException() { -// UIFind find = setUp(); Assert.assertEquals(find.findIndexOfElementWithText( find.findElements(automationPageModel.notInPage), "not In page"), 0); } @@ -196,7 +183,6 @@ public void findIndexOfElementInCollectionThrowException() { */ @Test(groups = TestCategories.SELENIUM) public void findIndexOfElementInCollectionNotFound() { -// UIFind find = setUp(); Assert.assertEquals(find.findIndexOfElementWithText(find.findElements(automationPageModel.flowerTable), "#notfound", false), -1); } @@ -207,7 +193,6 @@ public void findIndexOfElementInCollectionNotFound() { */ @Test(groups = TestCategories.SELENIUM) public void findIndexOfElementInCollectionEmptyInputList() { -// UIFind find = UIFindFactory.getFind(this.getWebDriver()); int index = find.findIndexOfElementWithText( (List) null, "#notfound", false); Assert.assertEquals(index, -1); @@ -219,7 +204,6 @@ public void findIndexOfElementInCollectionEmptyInputList() { */ @Test(groups = TestCategories.SELENIUM) public void findIndexOfElementInCollectionTextNotFoundAssertIsTrue() { -// UIFind find = setUp(); int index = find.findIndexOfElementWithText(find.findElements(automationPageModel.flowerTable), "#notfound", false); Assert.assertEquals(index, -1); diff --git a/openmaqs-utilities/src/test/java/io/github/openmaqs/utilities/helper/ConfigUnitTest.java b/openmaqs-utilities/src/test/java/io/github/openmaqs/utilities/helper/ConfigUnitTest.java index f6a8a611..957159b4 100644 --- a/openmaqs-utilities/src/test/java/io/github/openmaqs/utilities/helper/ConfigUnitTest.java +++ b/openmaqs-utilities/src/test/java/io/github/openmaqs/utilities/helper/ConfigUnitTest.java @@ -12,6 +12,7 @@ /** * The Configuration unit test class. */ +@Test(singleThreaded = true) public class ConfigUnitTest { /** diff --git a/openmaqs-utilities/src/test/java/io/github/openmaqs/utilities/logger/LoggerFactoryUnitTest.java b/openmaqs-utilities/src/test/java/io/github/openmaqs/utilities/logger/LoggerFactoryUnitTest.java index 4c5836b5..859d0242 100644 --- a/openmaqs-utilities/src/test/java/io/github/openmaqs/utilities/logger/LoggerFactoryUnitTest.java +++ b/openmaqs-utilities/src/test/java/io/github/openmaqs/utilities/logger/LoggerFactoryUnitTest.java @@ -16,7 +16,6 @@ import java.util.ArrayList; import java.util.HashMap; import java.util.List; - import org.testng.Assert; import org.testng.annotations.Test;