build: add ESLint to script/lint and containerize linting (closes #152)
This commit was merged in pull request #286.
This commit is contained in:
@@ -88,7 +88,7 @@ class Driver {
|
||||
let parsed;
|
||||
try {
|
||||
parsed = JSON.parse(text);
|
||||
} catch (_) {
|
||||
} catch {
|
||||
throw new Error(
|
||||
method + " " + path + ": non-JSON response: " + text,
|
||||
);
|
||||
@@ -229,7 +229,9 @@ class Driver {
|
||||
// condition it was waiting on rather than "timed out".
|
||||
async waitFor(what, script, args = [], timeout = DEFAULT_WAIT_MS) {
|
||||
const deadline = Date.now() + timeout;
|
||||
let last = null;
|
||||
// Assigned on every path through the loop body before it is read, so
|
||||
// there is no initializer to give it.
|
||||
let last;
|
||||
for (;;) {
|
||||
try {
|
||||
const v = await this.execute(script, args);
|
||||
@@ -512,7 +514,7 @@ async function waitForDriverReady(base, timeoutMs) {
|
||||
const body = await res.json();
|
||||
if (body && body.value && body.value.ready !== false) return;
|
||||
}
|
||||
} catch (_) {
|
||||
} catch {
|
||||
// not listening yet
|
||||
}
|
||||
if (Date.now() >= deadline) {
|
||||
|
||||
Reference in New Issue
Block a user