https://github.com/antonyhaman/youtube-autotests
Test task for one of the companies
https://github.com/antonyhaman/youtube-autotests
Last synced: 7 months ago
JSON representation
Test task for one of the companies
- Host: GitHub
- URL: https://github.com/antonyhaman/youtube-autotests
- Owner: antonyhaman
- Created: 2017-06-25T12:45:22.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-06-26T13:55:24.000Z (over 8 years ago)
- Last Synced: 2025-01-15T07:28:04.441Z (9 months ago)
- Language: Java
- Size: 8.02 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# youtube-autotests
Test task for an interview in one of the companiesThe task was as following:
> Goal:
determine, does video have preroll ads or not for both cases when adblock on and off
>Requirements: web-driver (chrome), any platform, any required software for sound recording.
>Pseudo scenario:
>adbock : on
>Find 10 most viewed video for “” on youtube.com and start playing one by one
>record sound _.
>when clip current time > 1 min, stop record, save file, start playing another
>when clip == 10, adblock : off, repeat, when adblock : off AND clip == 10; goto next step
>compare equals audio files - and return was preroll or not
>Output :
>, (true, false)## Technologies used
- Java
- Selenide
- TestNG
- musicg (for audio comparison)## Platform
Windows only. Could be easily modified to work on Linux.## How to install and run
This is Java Maven-based project so you have to have JRE and Maven installed on your pc and then:
1. Clone the project
2. Execute 'mvn test' in a command line, this will launch the tests
3. Check the results in log file at root of the project### Note:
Currently test is configured to record 20 audio files in total (it comes from the goal) each for 1 minute therefore test runs for about 20 minutes, if you don't want to wait so long, you can modify the following fields at TestSuite class:
```java
private final static int NUMBER_OF_VIDEOS = 10;
private final static int DURATION_MINUTES = 1;
private final static int DURATION_SECONDS = 0;
```