Skip to content

Commit

Permalink
chore: generate changeset
Browse files Browse the repository at this point in the history
  • Loading branch information
SebastianSedzik committed Jan 4, 2024
1 parent 3bb0b86 commit f41c5c4
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .changeset/ninety-pants-speak.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Add `@debug` decorator

Runs a `@test`(s) or `@suite`(s) in debug mode.
`@test`(s) or `@suite`(s) lacking the `@debug` decorator will be excluded.
Tests or suites without the `@debug` decorator will not be excluded.
Learn more about debug mode: https://playwright.dev/docs/debug

```ts
Expand Down
28 changes: 28 additions & 0 deletions .changeset/stale-avocados-mix.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
'playwright-decorators': minor
---

Add `@preview` decorator

Runs a `@test`(s) or `@suite`(s) in preview (headed browser) mode, simulating user interaction (slowing down each operation by 1000ms).
Tests or suites without the `@preview` decorator will not be excluded.

```ts
import { suite, test, preview, TestArgs } from 'playwright-decorators';

// Preview selected test suite(s)
@preview() // <-- Decorate suite with @preview()
@suite()
class PreviewTestSuite {
}

// Or preview selected test(s)
@suite()
class TestSuite {
@preview() // <-- Decorate test with @preview()
@test()
async test({ page }: TestArgs) {
// ...
}
}
```

0 comments on commit f41c5c4

Please sign in to comment.