Skip to content
This repository has been archived by the owner on Sep 3, 2024. It is now read-only.

Commit

Permalink
Merge pull request #403 from sbtqa/migrate-to-native-wdm
Browse files Browse the repository at this point in the history
Migrate to native wdm
  • Loading branch information
clicman authored Aug 30, 2023
2 parents 6604859 + 2adedec commit 9509fcb
Show file tree
Hide file tree
Showing 28 changed files with 145 additions and 275 deletions.
2 changes: 1 addition & 1 deletion page-factory-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<groupId>ru.sbtqa.tag</groupId>
<artifactId>page-factory-2</artifactId>
<version>17.0-SNAPSHOT</version>
<relativePath>../</relativePath>
<relativePath>../pom.xml</relativePath>
</parent>

<groupId>ru.sbtqa.tag.pagefactory</groupId>
Expand Down
2 changes: 1 addition & 1 deletion page-factory-core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<groupId>ru.sbtqa.tag</groupId>
<artifactId>page-factory-2</artifactId>
<version>17.0-SNAPSHOT</version>
<relativePath>../</relativePath>
<relativePath>../pom.xml</relativePath>
</parent>

<groupId>ru.sbtqa.tag.pagefactory</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.nio.charset.Charset;
import java.nio.charset.StandardCharsets;
import java.util.ArrayList;
import java.util.Arrays;
Expand Down
2 changes: 1 addition & 1 deletion page-factory-doc/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<groupId>ru.sbtqa.tag</groupId>
<artifactId>page-factory-2</artifactId>
<version>17.0-SNAPSHOT</version>
<relativePath>../</relativePath>
<relativePath>../pom.xml</relativePath>
</parent>

<groupId>ru.sbtqa.tag.pagefactory</groupId>
Expand Down
4 changes: 2 additions & 2 deletions plugins/html-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<groupId>ru.sbtqa.tag</groupId>
<artifactId>page-factory-2</artifactId>
<version>17.0-SNAPSHOT</version>
<relativePath>../..</relativePath>
<relativePath>../../pom.xml</relativePath>
</parent>

<groupId>ru.sbtqa.tag.pagefactory</groupId>
Expand All @@ -17,7 +17,7 @@

<properties>
<renamed.war>test-web-app.war</renamed.war>
<jetty.version>9.4.13.v20181111</jetty.version>
<jetty.version>9.4.27.v20200227</jetty.version>
<skipTests>false</skipTests>
</properties>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,20 @@

import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
import org.apache.log4j.BasicConfigurator;
import org.apache.log4j.Level;
import org.apache.log4j.Logger;
import org.junit.BeforeClass;
import org.junit.runner.RunWith;

@RunWith(Cucumber.class)
@CucumberOptions(monochrome = true, plugin = {"pretty"},
glue = {"ru.sbtqa.tag.stepdefs", "setting"},
features = {"src/test/resources/features"})
public class CucumberTest {
@BeforeClass
public static void setup() {
BasicConfigurator.configure();
Logger.getRootLogger().setLevel(Level.INFO);
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
package ru.sbtqa.tag.pagefactory;

import org.apache.log4j.BasicConfigurator;
import org.apache.log4j.Level;
import org.apache.log4j.Logger;
import org.junit.After;
import org.junit.Before;
import org.junit.BeforeClass;
Expand All @@ -20,6 +23,8 @@ public class JunitTest {

@BeforeClass
public static void before() throws Exception {
BasicConfigurator.configure();
Logger.getRootLogger().setLevel(Level.INFO);
server.startJetty();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,12 @@ screenshot.strategy=driver
webdriver.browser.name=Chrome
webdriver.starting.url=http://localhost:8181

# run chrome in headless mode
webdriver.chrome.capability.options.args=headless,disable-gpu,no-sandbox,--remote-allow-origins=*
# Run in headless mode
webdriver.chrome.capability.options.args=headless,disable-gpu,no-sandbox,remote-allow-origins=*
webdriver.edge.capability.options.args=headless,disable-gpu,no-sandbox,remote-allow-origins=*
webdriver.firefox.capability.options.args=headless

#Situable for headless firefox
#webdriver.browser.size=10980x1080

junit.lang = en
20 changes: 19 additions & 1 deletion plugins/mobile-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<groupId>ru.sbtqa.tag</groupId>
<artifactId>page-factory-2</artifactId>
<version>17.0-SNAPSHOT</version>
<relativePath>../..</relativePath>
<relativePath>../../pom.xml</relativePath>
</parent>

<groupId>ru.sbtqa.tag.pagefactory</groupId>
Expand All @@ -27,11 +27,24 @@
<artifactId>page-factory-core</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
<version>${gson.version}</version>
</dependency>
<dependency>
<groupId>io.appium</groupId>
<artifactId>java-client</artifactId>
<version>8.3.0</version>
<exclusions>
<exclusion>
<groupId>org.ow2.asm</groupId>
<artifactId>asm</artifactId>
</exclusion>
<exclusion>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
</exclusion>
<exclusion>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-remote-driver</artifactId>
Expand Down Expand Up @@ -63,6 +76,11 @@
<artifactId>cglib</artifactId>
<version>3.2.5</version>
</dependency>
<dependency>
<groupId>org.ow2.asm</groupId>
<artifactId>asm</artifactId>
<version>7.2</version>
</dependency>
</dependencies>

<build>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
import org.apache.log4j.BasicConfigurator;
import org.apache.log4j.Level;
import org.apache.log4j.Logger;
import org.junit.BeforeClass;
import org.junit.Ignore;
import org.junit.runner.RunWith;

Expand All @@ -13,4 +17,10 @@
)
public class CucumberTest {

@BeforeClass
public static void setup() {
BasicConfigurator.configure();
Logger.getRootLogger().setLevel(Level.INFO);
}

}
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
package pagefactory.mobile;

import org.apache.log4j.BasicConfigurator;
import org.apache.log4j.Level;
import org.apache.log4j.Logger;
import org.junit.BeforeClass;
import org.junit.Ignore;
import org.junit.Test;
import ru.sbtqa.tag.pagefactory.exceptions.PageException;
Expand All @@ -8,6 +12,12 @@
@Ignore
public class JunitTest {

@BeforeClass
public static void setupClass() {
BasicConfigurator.configure();
Logger.getRootLogger().setLevel(Level.INFO);
}

@Test
public void mobileTest() throws PageException {
MobileSteps.getInstance()
Expand Down
2 changes: 1 addition & 1 deletion plugins/mq-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<artifactId>page-factory-2</artifactId>
<groupId>ru.sbtqa.tag</groupId>
<version>17.0-SNAPSHOT</version>
<relativePath>../..</relativePath>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
package ru.sbtqa.tag.mq;

import org.apache.activemq.ActiveMQConnectionFactory;
import org.junit.After;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;
import org.apache.log4j.BasicConfigurator;
import org.apache.log4j.Level;
import org.junit.*;
import org.junit.runner.RunWith;
import org.junit.runners.JUnit4;
import org.slf4j.Logger;
Expand Down Expand Up @@ -38,6 +37,12 @@ public class ActiveMqTest {
private QueueConnection mQueueConnection;
private Jms<TextMessage> mqService;

@BeforeClass
public static void setupClass() {
BasicConfigurator.configure();
org.apache.log4j.Logger.getRootLogger().setLevel(Level.INFO);
}

@Before
public void beforeTest() {
mQueueConnection = null;
Expand Down
20 changes: 4 additions & 16 deletions plugins/rest-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<groupId>ru.sbtqa.tag</groupId>
<artifactId>page-factory-2</artifactId>
<version>17.0-SNAPSHOT</version>
<relativePath>../..</relativePath>
<relativePath>../../pom.xml</relativePath>
</parent>

<groupId>ru.sbtqa.tag.pagefactory</groupId>
Expand All @@ -31,7 +31,7 @@
<dependency>
<groupId>io.rest-assured</groupId>
<artifactId>rest-assured</artifactId>
<version>3.3.0</version>
<version>5.3.1</version>
<exclusions>
<exclusion>
<artifactId>commons-lang3</artifactId>
Expand All @@ -47,7 +47,7 @@
<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
<version>2.10</version>
<version>${gson.version}</version>
</dependency>

<!--TESTS-->
Expand All @@ -60,19 +60,7 @@
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-servlet</artifactId>
<version>9.4.27.v20200227</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-impl</artifactId>
<version>2.2.11</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-core</artifactId>
<version>2.2.11</version>
<version>11.0.15</version>
<scope>test</scope>
</dependency>
<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

import cucumber.api.CucumberOptions;
import cucumber.api.junit.Cucumber;
import org.apache.log4j.BasicConfigurator;
import org.apache.log4j.Level;
import org.apache.log4j.Logger;
import org.eclipse.jetty.server.Server;
import org.junit.AfterClass;
import org.junit.BeforeClass;
Expand All @@ -20,6 +23,8 @@ public class CucumberTest {

@BeforeClass
public static void setup() {
BasicConfigurator.configure();
Logger.getRootLogger().setLevel(Level.INFO);
server = JettyServiceUtils.startJetty();
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
package ru.sbtqa.tag.api;

import org.apache.log4j.BasicConfigurator;
import org.apache.log4j.Level;
import org.apache.log4j.Logger;
import org.eclipse.jetty.server.Server;
import org.junit.AfterClass;
import org.junit.BeforeClass;
Expand Down Expand Up @@ -31,6 +34,8 @@ public class JunitTests {

@BeforeClass
public static void setupClass() {
BasicConfigurator.configure();
Logger.getRootLogger().setLevel(Level.INFO);
server = JettyServiceUtils.startJetty();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public class SecondRequestFromFeatureEntry extends EndpointEntry {
@Validation(title = "result")
public void validate() {
getResponse().body("result", equalTo("q1=" + Default.HEADER_PARAMETER_VALUE_1 + "|" + "q2=" + Default.QUERY_PARAMETER_VALUE_1
+ "|" + "h1=" + Default.HEADER_PARAMETER_VALUE_1 + "|" + "h2=application/json; charset=UTF-8|"
+ "|" + "h1=" + Default.HEADER_PARAMETER_VALUE_1 + "|" + "h2=application/json|"
+ "id=" + Default.ID + "|" + "name=" + Default.NAME + "|" + "email=parameter-value|"));
}
}
8 changes: 4 additions & 4 deletions plugins/web-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<groupId>ru.sbtqa.tag</groupId>
<artifactId>page-factory-2</artifactId>
<version>17.0-SNAPSHOT</version>
<relativePath>../..</relativePath>
<relativePath>../../pom.xml</relativePath>
</parent>

<groupId>ru.sbtqa.tag.pagefactory</groupId>
Expand All @@ -19,7 +19,7 @@

<properties>
<renamed.war>test-web-app.war</renamed.war>
<jetty.version>9.4.13.v20181111</jetty.version>
<jetty.version>9.4.27.v20200227</jetty.version>
<skipTests>false</skipTests>
</properties>

Expand All @@ -30,9 +30,9 @@
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>ru.sbtqa</groupId>
<groupId>io.github.bonigarcia</groupId>
<artifactId>webdrivermanager</artifactId>
<version>${tag.version.webdrivermanager}</version>
<version>${webdrivermanager.version}</version>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
Expand Down
Loading

0 comments on commit 9509fcb

Please sign in to comment.