Skip to content

TomashGombosh/java-web-test-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Web e2e tests demo project TeamCity Status Build

Table of contents

Preconditions

Windows

Install and Setup Java
  1. Install Java 8 or higher on your local machine. To download Java 8 jdk click on that and install java for Windows.
  2. To set up JAVA_HOME follow next steps:
    1. Click left button of the mouse on the 'My computer' icon and choose 'Settings' in the drop-down list;
    2. In the 'System' window click 'Additional parameters of the system';
    3. Click on button 'Environment variables';
    4. In the modal window 'System variables' click button 'Add';
    5. In the field 'Variable name' fill 'JAVA_HOME';
    6. In the field 'Variable value' fill ;
    7. Click 'OK' button;
    8. Open 'PATH' in the 'System variables';
    9. In the bottom of the list add %JAVA_HOME%\lib, %JAVA_HOME%\bin and %JAVA_HOME%\jre;
  3. To check the acceptance of changes, open the command line of your machine and run the following 'path' command, at the end of the change you need to set \lib,\bin and \jre

Mac OS

  1. Install with Homebrew
    1. Install Homebrew using the command (if the homebrew already installed into you mac os skip that step) /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
    2. Install java 8 using command brew tap adoptopenjdk/openjdk && brew cask install adoptopenjdk8
    3. Set JAVA_HOME using command export JAVA_HOME=/path/to/java (usually for homebrew install it would be /Library/Java/JavaVirtualMachines/jdk/Contents/Home)
    4. Set JAVA_HOME to the patch using command PATH=$JAVA_HOME/lib:$JAVA_HOME/bin:$JAVA_HOME/jre:$PATH

Run using IDE

  • Install IntelliJ IDEA IDE
  • Install Lombok Plugin: IntelliJ IDEA > Preferences > Plugins > Browse repositories > Lombok Plugin
  • Enable annotation processing: IntelliJ IDEA > Preferences > Build, Execution, Deployment > Compiler > Annotation Processors > Enable annotation processing
  • Checkout project from git
  • Start import as Maven project
  • Go to the src/test/resources/ click on the right button and click Run 'Test' in 'ExpediteSuite.xml...'

Run using command line

  • Checkout project from git
  • Go to the checkout folder using cd java-web-test-demo
  • Start test using command for Windows: mvnw.cmd clean test for macOS: ./mvnw clean test
  • After test finished to generate the report using next command for Windows mvnw.cmd allureReport && mvnw.cmd allureServe for macOS: ./mvnw allure:report && ./mvnw mvn allure:serve

Run on the Team City

  • Go to the Team City server
  • Login to the server (To get credential to the server please contact me)
  • Open Web e2e test Build and Test under AFJ Solution project
  • Click Run
  • To see report go to Open build with name API integration tests Build and Test > Artifacts > Collapse allure-report.zip > Click on the index.html

About

Java + Maven + Selenium + Test NG demo project

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages