Skip to content

Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.

docs: Improve clock doc (#31147)

Darío Kondratiuk76b25e84cc90
diff --git a/docs/src/api/class-clock.md b/docs/src/api/class-clock.md
index 95fa0b69d3..31115db41b 100644
--- a/docs/src/api/class-clock.md
+++ b/docs/src/api/class-clock.md
@@ -106,7 +106,7 @@ Returns fake milliseconds since the unix epoch.
* since: v1.45
- returns: <[int]>
-Advances the clock to the the moment of the first scheduled timer, firing it.
+Advances the clock to the moment of the first scheduled timer, firing it.
Fake timers must be installed.
Returns fake milliseconds since the unix epoch.
diff --git a/docs/src/clock.md b/docs/src/clock.md
index 4339e4bc60..5299145916 100644
--- a/docs/src/clock.md
+++ b/docs/src/clock.md
@@ -202,7 +202,7 @@ await page.goto('http://localhost:3333');
// Tick through time manually, firing all timers in the process.
// In this case, time will be updated in the screen 2 times.
await page.clock.runFor(2000);
-await expect(locator).to_have_text('2/2/2024, 10:00:02 AM')
+await expect(locator).to_have_text('2/2/2024, 10:00:02 AM');
```
```python async
diff --git a/packages/playwright-core/src/utils/isomorphic/cssTokenizer.ts b/packages/playwright-core/src/utils/isomorphic/cssTokenizer.ts
index f72ef27eb4..43b0a45869 100644
--- a/packages/playwright-core/src/utils/isomorphic/cssTokenizer.ts
+++ b/packages/playwright-core/src/utils/isomorphic/cssTokenizer.ts
@@ -378,7 +378,7 @@ export function tokenize(str1: string): CSSTokenInterface[] {
};
const consumeEscape = function() {
- // Assume the the current character is the \
+ // Assume the current character is the \
// and the next code point is not a newline.
consume();
if (hexdigit(code)) {
diff --git a/packages/playwright-core/types/types.d.ts b/packages/playwright-core/types/types.d.ts
index 92a3b130df..dc91c655f0 100644
--- a/packages/playwright-core/types/types.d.ts
+++ b/packages/playwright-core/types/types.d.ts
@@ -17311,8 +17311,8 @@ export interface Clock {
runToLastTimer(): Promise<number>;
/**
- * Advances the clock to the the moment of the first scheduled timer, firing it. Fake timers must be installed.
- * Returns fake milliseconds since the unix epoch.
+ * Advances the clock to the moment of the first scheduled timer, firing it. Fake timers must be installed. Returns
+ * fake milliseconds since the unix epoch.
*/
runToNextTimer(): Promise<number>;