Skip to content

Commit 4326646

Browse files
author
“Rajat
committed
#23: 🚀 Optimizations
1 parent 8e10789 commit 4326646

10 files changed

+14
-13
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
- [Contacts](#contacts)
4040

4141
## 📖 Introduction
42-
This repository contains a Test Automation Framework built using Playwright and Javascript for automated testing of REST APIs.
42+
This repository contains a **Test Automation Framework** built using **Playwright** and **Javascript** for automated testing of **REST APIs**.
4343

4444
<!-- ## 🎥 Video Tutorial
4545
@@ -54,19 +54,19 @@ Click on the image above to watch the tutorials. -->
5454

5555
## ▶️ Getting Started
5656

57-
1. Clone the repository:
57+
1. **Clone the repository:**
5858

5959
```bash
6060
git clone https://github.com/rajatt95/TestAutomationFramework_YT_Rajat_API_Playwright_JS.git
6161
```
6262

63-
2. Navigate to the project directory:
63+
2. **Navigate to the project directory:**
6464

6565
```bash
6666
cd TestAutomationFramework_YT_Rajat_API_Playwright_JS
6767
```
6868

69-
3. Install dependencies:
69+
3. **Install dependencies:**
7070

7171
```bash
7272
npm install

tests-reqres/users.spec.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,9 @@ test.describe('Users', () => {
126126
VerificationUtils.assertResponseBodyKeyPresent(responseBody.data[0], 'last_name');
127127
VerificationUtils.assertResponseBodyKeyPresent(responseBody.data[0], 'avatar');
128128

129-
VerificationUtils.assertResponseBodyKeyValue(responseBody.support, 'text', 'To keep ReqRes free, contributions towards server costs are appreciated!');
130-
129+
// VerificationUtils.assertResponseBodyKeyValue(responseBody.support, 'text', 'To keep ReqRes free, contributions towards server costs are appreciated!');
130+
VerificationUtils.assertResponseBodyKeyValue(responseBody.support, 'text', 'Tired of writing endless social media content? Let Content Caddy generate it for you.');
131+
131132
})
132133

133134

utils/RequestBodyUtils.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
import requestBodyRegisterSuccessful from '../test-data/register/register-successful.json';
2-
import requestBodyRegisterUnsuccessful from '../test-data/register/register-unsuccessful.json';
1+
import requestBodyRegisterSuccessful from '../test-data/request-body/register/register-successful.json';
2+
import requestBodyRegisterUnsuccessful from '../test-data/request-body/register/register-unsuccessful.json';
33

4-
import requestBodyLoginSuccessful from '../test-data/login/login-successful.json';
5-
import requestBodyLoginUnsuccessful from '../test-data/login/login-unsuccessful.json';
4+
import requestBodyLoginSuccessful from '../test-data/request-body/login/login-successful.json';
5+
import requestBodyLoginUnsuccessful from '../test-data/request-body/login/login-unsuccessful.json';
66

7-
import requestBodyUserCreate from '../test-data/users/user_create.json';
8-
import requestBodyUserUpdatePut from '../test-data/users/user_update_put.json';
9-
import requestBodyUserUpdatePatch from '../test-data/users/user_update_patch.json';
7+
import requestBodyUserCreate from '../test-data/request-body/users/user_create.json';
8+
import requestBodyUserUpdatePut from '../test-data/request-body/users/user_update_put.json';
9+
import requestBodyUserUpdatePatch from '../test-data/request-body/users/user_update_patch.json';
1010

1111
/**
1212
* Utility class for managing and providing request body data for various scenarios.

0 commit comments

Comments
 (0)