{"id":26584039,"url":"https://github.com/dnv-opensource/playwright-duration","last_synced_at":"2026-04-22T21:34:05.563Z","repository":{"id":237975220,"uuid":"794669846","full_name":"dnv-opensource/playwright-duration","owner":"dnv-opensource","description":"Override playwright's duration within a test. Better performance accuracy when wanting to measure timing for only part of a test.","archived":false,"fork":false,"pushed_at":"2024-05-03T15:47:32.000Z","size":5,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-05T12:48:32.958Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dnv-opensource.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"zenodo":null}},"created_at":"2024-05-01T17:49:07.000Z","updated_at":"2024-05-03T15:49:13.000Z","dependencies_parsed_at":null,"dependency_job_id":"958aa62e-540e-49a8-a8a2-770ec4000f81","html_url":"https://github.com/dnv-opensource/playwright-duration","commit_stats":null,"previous_names":["dnv-opensource/playwright-duration"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/dnv-opensource/playwright-duration","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dnv-opensource%2Fplaywright-duration","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dnv-opensource%2Fplaywright-duration/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dnv-opensource%2Fplaywright-duration/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dnv-opensource%2Fplaywright-duration/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dnv-opensource","download_url":"https://codeload.github.com/dnv-opensource/playwright-duration/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dnv-opensource%2Fplaywright-duration/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32156603,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-22T17:06:48.269Z","status":"ssl_error","status_checked_at":"2026-04-22T17:06:19.037Z","response_time":58,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":[],"created_at":"2025-03-23T09:17:47.498Z","updated_at":"2026-04-22T21:34:05.557Z","avatar_url":"https://github.com/dnv-opensource.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# playwright-duration\n\nMicro lib to allow fine grained control of reported test time on tests.  \nUseful when measuring performance for single user workflow tests.\n\n# Installation\n``` sh\nnpm install --save-dev @dnvgl/playwright-duration\n```\n\n# Usage\ngiven a playwright test, import and wrap the `duration` function around the code under test you'd like to time  \n\nExample:\n``` ts\nimport { test, expect } from '@playwright/test';\nimport { duration } from '@dnvgl/playwright-duration';\n\ntest('get started link', async ({ page }, testInfo) =\u003e {\n  //test setup\n  await page.goto('https://playwright.dev/');\n\n  //after main page load, would like to measure the time to load the `Get started` link\n  await duration(testInfo, async () =\u003e {\n    await page.getByRole('link', { name: 'Get started' }).click();\n    await expect(page.getByRole('heading', { name: 'Installation' })).toBeVisible();\n  });\n});\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdnv-opensource%2Fplaywright-duration","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdnv-opensource%2Fplaywright-duration","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdnv-opensource%2Fplaywright-duration/lists"}