rename Deno.Err -> Deno.errors (#4093)

This commit is contained in:
Bartek Iwańczuk 2020-02-24 15:48:35 -05:00 committed by GitHub
parent db59705595
commit e1687c0a46
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
42 changed files with 137 additions and 137 deletions

View file

@ -23,7 +23,7 @@ testPerm({ read: false }, async function statSyncPerm(): Promise<void> {
Deno.statSync("README.md");
} catch (e) {
caughtError = true;
assert(e instanceof Deno.Err.PermissionDenied);
assert(e instanceof Deno.errors.PermissionDenied);
}
assert(caughtError);
});
@ -36,7 +36,7 @@ testPerm({ read: true }, async function statSyncNotFound(): Promise<void> {
badInfo = Deno.statSync("bad_file_name");
} catch (err) {
caughtError = true;
assert(err instanceof Deno.Err.NotFound);
assert(err instanceof Deno.errors.NotFound);
}
assert(caughtError);
@ -63,7 +63,7 @@ testPerm({ read: false }, async function lstatSyncPerm(): Promise<void> {
Deno.lstatSync("README.md");
} catch (e) {
caughtError = true;
assert(e instanceof Deno.Err.PermissionDenied);
assert(e instanceof Deno.errors.PermissionDenied);
}
assert(caughtError);
});
@ -76,7 +76,7 @@ testPerm({ read: true }, async function lstatSyncNotFound(): Promise<void> {
badInfo = Deno.lstatSync("bad_file_name");
} catch (err) {
caughtError = true;
assert(err instanceof Deno.Err.NotFound);
assert(err instanceof Deno.errors.NotFound);
}
assert(caughtError);
@ -103,7 +103,7 @@ testPerm({ read: false }, async function statPerm(): Promise<void> {
await Deno.stat("README.md");
} catch (e) {
caughtError = true;
assert(e instanceof Deno.Err.PermissionDenied);
assert(e instanceof Deno.errors.PermissionDenied);
}
assert(caughtError);
});
@ -116,7 +116,7 @@ testPerm({ read: true }, async function statNotFound(): Promise<void> {
badInfo = await Deno.stat("bad_file_name");
} catch (err) {
caughtError = true;
assert(err instanceof Deno.Err.NotFound);
assert(err instanceof Deno.errors.NotFound);
}
assert(caughtError);
@ -143,7 +143,7 @@ testPerm({ read: false }, async function lstatPerm(): Promise<void> {
await Deno.lstat("README.md");
} catch (e) {
caughtError = true;
assert(e instanceof Deno.Err.PermissionDenied);
assert(e instanceof Deno.errors.PermissionDenied);
}
assert(caughtError);
});
@ -156,7 +156,7 @@ testPerm({ read: true }, async function lstatNotFound(): Promise<void> {
badInfo = await Deno.lstat("bad_file_name");
} catch (err) {
caughtError = true;
assert(err instanceof Deno.Err.NotFound);
assert(err instanceof Deno.errors.NotFound);
}
assert(caughtError);