Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mefepolat/the-internet-automation-java-selenium
Automation tests for the-internet.herokuapp.com with Java Selenium WebDriver and TestNG
https://github.com/mefepolat/the-internet-automation-java-selenium
automation automation-framework automation-selenium automation-testing java selenium selenium-java selenium-webdriver testng testng-framework
Last synced: 3 days ago
JSON representation
Automation tests for the-internet.herokuapp.com with Java Selenium WebDriver and TestNG
- Host: GitHub
- URL: https://github.com/mefepolat/the-internet-automation-java-selenium
- Owner: mefepolat
- Created: 2023-06-03T20:20:13.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2023-06-07T01:12:19.000Z (over 1 year ago)
- Last Synced: 2024-08-01T21:58:43.704Z (3 months ago)
- Topics: automation, automation-framework, automation-selenium, automation-testing, java, selenium, selenium-java, selenium-webdriver, testng, testng-framework
- Language: Java
- Homepage: https://the-internet.herokuapp.com
- Size: 6.13 MB
- Stars: 5
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Test Automation for the-internet.herokuapp.com
This project contains automation tests written in Java using Selenium WebDriver and TestNG for the website the-internet.herokuapp.com. The purpose of these tests is to improve your test automation skills and demonstrate how to automate different scenarios on the website.Project Structure
The project is structured as follows:```
|-- src
| |-- main
| | |-- java
| | | |-- pages
| |-- HomePage.java
| |-- LoginPage.java
| |-- ...
| | |-- resources
| |
| |-- test
| |-- java
| |-- base
| |-- BaseTests.java
| |-- login
| |-- LoginTests.java
| |-- ...
| |-- resources
|
|-- .gitignore
|-- pom.xml
|-- README.md
```- The src directory contains the main source code and test code.
- The src/main/java directory is where you can place any utility classes framework or page object model classes.
- The src/test/java directory contains the test classes where you'll write your test cases.
- The src/test/resources directory is where you can store any test-specific resources, such as test data files or configuration files.
- The src/test/resources/testng.xml file is the TestNG configuration file where you can configure your test suites, test groups, and other settings.
- The .gitignore file specifies which files and directories should be ignored by Git version control.## Prerequisites
To run the automation tests in this project, you'll need to have the following software installed on your machine:- Java Development Kit (JDK) 10 or higher
- Apache Maven
- Selenium WebDriver
- TestNG## Running the Tests
Follow these steps to run the automation tests:- Clone the repository to your local machine: $ git clone
- Navigate to the project directory: $ cd project-directory
- Build the project using Maven: $ mvn clean install
- Execute the tests using the TestNG runner: $ mvn test
##Writing Test Cases
To create new test cases or modify existing ones, follow these guidelines:- Create a new Java class under src/test/java/ or add your test cases to an existing class.
- Use the TestNG annotations (@Test, @BeforeMethod, @AfterMethod, etc.) to define your test methods and set up/tear down steps.
- Leverage Selenium WebDriver API to interact with the web elements on the website under test.
- Implement assertions to verify the expected outcomes of your test cases.
## Continuous Integration
You can integrate this project with any Continuous Integration (CI) tool of your choice, such as Jenkins or Travis CI. Set up a CI pipeline to automatically build and execute the tests on each commit or at specific intervals.## Contributing
Contributions to this test automation project are welcome. If you find any bugs, issues, or have suggestions for improvements, please open an issue or submit a pull request.