{"id":21480460,"url":"https://github.com/codewithmmak/playwright-javascript","last_synced_at":"2025-07-15T12:31:59.857Z","repository":{"id":40359920,"uuid":"489247951","full_name":"codewithmmak/playwright-javascript","owner":"codewithmmak","description":"This is a test automation framework designed using Playwright and JavaScript.","archived":false,"fork":false,"pushed_at":"2024-10-29T14:26:00.000Z","size":508,"stargazers_count":19,"open_issues_count":10,"forks_count":9,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-10-29T17:35:28.508Z","etag":null,"topics":["e2e-boilerplate","e2e-framework","e2e-tests","javascript","nextjs","nextjs-testing","playwright","playwright-javascript","playwright-test-runner","playwright-tests","test-automation"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/codewithmmak.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-05-06T06:51:23.000Z","updated_at":"2024-09-30T11:31:50.000Z","dependencies_parsed_at":"2024-01-04T01:55:22.569Z","dependency_job_id":"08c1e6ef-eb86-425b-bf5c-563681e7f09e","html_url":"https://github.com/codewithmmak/playwright-javascript","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codewithmmak%2Fplaywright-javascript","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codewithmmak%2Fplaywright-javascript/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codewithmmak%2Fplaywright-javascript/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codewithmmak%2Fplaywright-javascript/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/codewithmmak","download_url":"https://codeload.github.com/codewithmmak/playwright-javascript/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":226038782,"owners_count":17564046,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["e2e-boilerplate","e2e-framework","e2e-tests","javascript","nextjs","nextjs-testing","playwright","playwright-javascript","playwright-test-runner","playwright-tests","test-automation"],"created_at":"2024-11-23T12:15:13.370Z","updated_at":"2024-11-23T12:15:13.927Z","avatar_url":"https://github.com/codewithmmak.png","language":"JavaScript","readme":"---\n# Playwright and JavaScript Setup Guide\n---\n\n## Features of this framework\n* [Design Pattern: Page Object Model](https://playwright.dev/docs/test-pom)\n* [Reporting: Allure](https://www.npmjs.com/package/allure-playwright)\n* [Cloud Integration: SauceLab](https://saucelabs.com/)\n* [Deep Deletion](https://www.npmjs.com/package/rimraf)\n\n## Getting started\n\n### Pre-requisites\n* Download and install Node.js\n* Download and install any Text Editor like Visual Code/Sublime/Brackets\n\n### Setup Visual Code\n* Install GitLens Extension from the Marketplace: `GitLens — Git supercharged by GitKraken https://marketplace.visualstudio.com/items?itemName=eamodio.gitlens`\n* Go to Visual Code Preference \u003e Setting and search `formatOnSave` and enable/ON it.\n\n### Setup Scripts \n* Clone the repository into a folder\n* Go to Project root directory and install Dependency: `npm install`\n* All the dependencies from package.json would be installed in node_modules folder.\n\n### How to write Test\n* Add new spec under `e2e-tests` folder\n* Name the file as \u003ctestname\u003e.spec.js (e.g. home.spec.js)\n* Create folder under page-objects/pages as \u003cpage-name\u003e (e.g. homePage)\n* Under page folder create constant, helper and page object file.\n    * \u003cpage-name\u003e.constants.js (e.g. home.constants.js)\n    * \u003cpage-name\u003e.helper.js (e.g. home.helper.js)\n    * \u003cpage-name\u003e.po.js (e.g. home.po.js)\n\n### How to Run Test\n* Go to Project root directory and run command: `npm test`\n* If you want to run e2e tests then run command: `npm run e2e`\n\n### How to Update local npm packages\n* Go to Project root directory and run command: `npm update`\n\n### How to view HTML report\n* Go to Project root directory: `./playwright-report/index.html`\n\n### How to view failed test screenshot\n* Go to Project root directory: `./test-results/`\n\n### Sample Allure Test Report\n![Playwright and JavaScript Test Report](./assets/test-report.png?raw=true \"Playwright and JavaScript Test Report\")\n\n![Playwright and JavaScript Test Report Expanded View](./assets/test-report-expanded-view.png?raw=true \"Playwright and JavaScript Test Report Expanded View\")\n\n\n### How to run Test on SauceLabs\n* [SauceLabs Quickstart](https://docs.saucelabs.com/web-apps/automated-testing/playwright/quickstart/)\n    * Set Environment Variables:\n        * Open Terminal\n        * Run `touch ~/.bash_profile; open ~/.bash_profile`\n        * In TextEdit, add\n        * `export SAUCE_USERNAME=“YOUR USERNAME”`\n        * `export SAUCE_ACCESS_KEY=\"YOUR ACCESS KEY\"`\n        * Save the .bash_profile file and Quit (Command + Q) Text Edit.\n        * In Terminal echo $SAUCE_USERNAME\n        * In Terminal echo $SAUCE_ACCESS_KEY\n    * Configure:\n    `saucectl config` \n    * Run tests: `npm saucectl run`\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodewithmmak%2Fplaywright-javascript","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodewithmmak%2Fplaywright-javascript","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodewithmmak%2Fplaywright-javascript/lists"}