summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.dprintrc.json2
-rw-r--r--Cargo.lock8
-rw-r--r--cli/Cargo.toml2
-rw-r--r--cli/tests/005_more_imports.ts2
-rw-r--r--cli/tests/bundle_im.ts2
-rw-r--r--cli/tests/lock_check_err_with_bundle.json2
-rw-r--r--cli/tests/lock_dynamic_imports.json2
-rw-r--r--cli/tests/single_compile_with_reload_dyn.ts2
-rw-r--r--cli/tests/subdir/mod1.ts2
-rw-r--r--cli/tests/unit/abort_controller_test.ts2
-rw-r--r--cli/tests/unit/blob_test.ts2
-rw-r--r--cli/tests/unit/body_test.ts6
-rw-r--r--cli/tests/unit/buffer_test.ts2
-rw-r--r--cli/tests/unit/build_test.ts2
-rw-r--r--cli/tests/unit/chmod_test.ts2
-rw-r--r--cli/tests/unit/chown_test.ts2
-rw-r--r--cli/tests/unit/copy_file_test.ts2
-rw-r--r--cli/tests/unit/custom_event_test.ts2
-rw-r--r--cli/tests/unit/dir_test.ts2
-rw-r--r--cli/tests/unit/dispatch_json_test.ts6
-rw-r--r--cli/tests/unit/dom_exception_test.ts2
-rw-r--r--cli/tests/unit/event_target_test.ts2
-rw-r--r--cli/tests/unit/event_test.ts2
-rw-r--r--cli/tests/unit/fetch_test.ts2
-rw-r--r--cli/tests/unit/file_test.ts2
-rw-r--r--cli/tests/unit/filereader_test.ts2
-rw-r--r--cli/tests/unit/files_test.ts2
-rw-r--r--cli/tests/unit/filter_function_test.ts2
-rw-r--r--cli/tests/unit/form_data_test.ts2
-rw-r--r--cli/tests/unit/fs_events_test.ts2
-rw-r--r--cli/tests/unit/get_random_values_test.ts2
-rw-r--r--cli/tests/unit/globals_test.ts2
-rw-r--r--cli/tests/unit/headers_test.ts2
-rw-r--r--cli/tests/unit/internals_test.ts2
-rw-r--r--cli/tests/unit/io_test.ts2
-rw-r--r--cli/tests/unit/link_test.ts2
-rw-r--r--cli/tests/unit/make_temp_test.ts2
-rw-r--r--cli/tests/unit/metrics_test.ts2
-rw-r--r--cli/tests/unit/mkdir_test.ts2
-rw-r--r--cli/tests/unit/net_test.ts4
-rw-r--r--cli/tests/unit/path_from_url_test.ts2
-rw-r--r--cli/tests/unit/performance_test.ts2
-rw-r--r--cli/tests/unit/permissions_test.ts2
-rw-r--r--cli/tests/unit/process_test.ts2
-rw-r--r--cli/tests/unit/progressevent_test.ts2
-rw-r--r--cli/tests/unit/read_dir_test.ts2
-rw-r--r--cli/tests/unit/read_file_test.ts2
-rw-r--r--cli/tests/unit/read_link_test.ts2
-rw-r--r--cli/tests/unit/read_text_file_test.ts2
-rw-r--r--cli/tests/unit/real_path_test.ts2
-rw-r--r--cli/tests/unit/remove_test.ts2
-rw-r--r--cli/tests/unit/rename_test.ts2
-rw-r--r--cli/tests/unit/request_test.ts2
-rw-r--r--cli/tests/unit/resources_test.ts2
-rw-r--r--cli/tests/unit/response_test.ts2
-rw-r--r--cli/tests/unit/signal_test.ts2
-rw-r--r--cli/tests/unit/stat_test.ts2
-rw-r--r--cli/tests/unit/stdio_test.ts2
-rw-r--r--cli/tests/unit/streams_internal_test.ts2
-rw-r--r--cli/tests/unit/streams_piping_test.ts2
-rw-r--r--cli/tests/unit/streams_transform_test.ts2
-rw-r--r--cli/tests/unit/streams_writable_test.ts2
-rw-r--r--cli/tests/unit/symlink_test.ts2
-rw-r--r--cli/tests/unit/sync_test.ts2
-rw-r--r--cli/tests/unit/test_util.ts6
-rw-r--r--cli/tests/unit/text_encoding_test.ts2
-rw-r--r--cli/tests/unit/timers_test.ts4
-rw-r--r--cli/tests/unit/tls_test.ts2
-rw-r--r--cli/tests/unit/truncate_test.ts2
-rw-r--r--cli/tests/unit/tty_test.ts2
-rw-r--r--cli/tests/unit/umask_test.ts2
-rwxr-xr-xcli/tests/unit/unit_test_runner.ts8
-rw-r--r--cli/tests/unit/url_search_params_test.ts2
-rw-r--r--cli/tests/unit/url_test.ts2
-rw-r--r--cli/tests/unit/utime_test.ts2
-rw-r--r--cli/tests/unit/version_test.ts2
-rw-r--r--cli/tests/unit/write_file_test.ts2
-rw-r--r--cli/tests/unit/write_text_file_test.ts2
-rw-r--r--docs/examples/import_export.md5
-rw-r--r--docs/examples/manage_dependencies.md5
-rw-r--r--docs/testing.md2
-rw-r--r--docs/tools/bundler.md2
-rw-r--r--std/_util/deep_assign_test.ts2
-rw-r--r--std/archive/tar_test.ts4
-rw-r--r--std/bytes/test.ts12
-rw-r--r--std/datetime/formatter.ts2
-rw-r--r--std/encoding/README.md6
-rw-r--r--std/encoding/_yaml/dumper/dumper_state.ts2
-rw-r--r--std/encoding/_yaml/schema.ts2
-rw-r--r--std/encoding/_yaml/type.ts2
-rw-r--r--std/encoding/_yaml/type/float.ts2
-rw-r--r--std/encoding/_yaml/type/int.ts2
-rw-r--r--std/encoding/ascii85_test.ts2
-rw-r--r--std/encoding/base32_test.ts4
-rw-r--r--std/encoding/base64_test.ts2
-rw-r--r--std/encoding/base64url_test.ts2
-rw-r--r--std/encoding/binary_test.ts4
-rw-r--r--std/encoding/csv_test.ts8
-rw-r--r--std/encoding/hex_test.ts10
-rw-r--r--std/examples/chat/server.ts4
-rw-r--r--std/examples/chat/server_test.ts2
-rw-r--r--std/examples/colors.ts2
-rw-r--r--std/examples/echo_server_test.ts2
-rw-r--r--std/examples/test.ts2
-rw-r--r--std/examples/xeval_test.ts2
-rw-r--r--std/fs/_util_test.ts2
-rw-r--r--std/fs/copy.ts2
-rw-r--r--std/fs/copy_test.ts2
-rw-r--r--std/fs/eol_test.ts2
-rw-r--r--std/fs/expand_glob.ts4
-rw-r--r--std/fs/expand_glob_test.ts4
-rw-r--r--std/fs/walk_test.ts2
-rw-r--r--std/hash/sha1_test.ts4
-rw-r--r--std/hash/sha256_test.ts4
-rw-r--r--std/hash/sha512_test.ts4
-rw-r--r--std/http/_io.ts2
-rw-r--r--std/http/_io_test.ts12
-rw-r--r--std/http/cookie_test.ts4
-rw-r--r--std/http/file_server.ts6
-rw-r--r--std/http/file_server_test.ts4
-rw-r--r--std/http/server.ts4
-rw-r--r--std/http/server_test.ts10
-rw-r--r--std/io/README.md4
-rw-r--r--std/io/bufio_test.ts4
-rw-r--r--std/io/streams_test.ts4
-rw-r--r--std/log/handlers.ts4
-rw-r--r--std/log/handlers_test.ts8
-rw-r--r--std/log/logger.ts2
-rw-r--r--std/log/logger_test.ts6
-rw-r--r--std/log/mod.ts2
-rw-r--r--std/log/mod_test.ts12
-rw-r--r--std/log/test.ts4
-rw-r--r--std/mime/multipart_test.ts4
-rw-r--r--std/node/_fs/_fs_appendFile.ts6
-rw-r--r--std/node/_fs/_fs_chmod_test.ts2
-rw-r--r--std/node/_fs/_fs_chown_test.ts2
-rw-r--r--std/node/_fs/_fs_close_test.ts2
-rw-r--r--std/node/_fs/_fs_link_test.ts2
-rw-r--r--std/node/_fs/_fs_readFile.ts8
-rw-r--r--std/node/_fs/_fs_readFile_test.ts2
-rw-r--r--std/node/_fs/_fs_readlink_test.ts2
-rw-r--r--std/node/_fs/_fs_writeFile.ts8
-rw-r--r--std/node/_fs/promises/_fs_readFile.ts2
-rw-r--r--std/node/_fs/promises/_fs_readFile_test.ts2
-rw-r--r--std/node/_util/_util_types_test.ts26
-rw-r--r--std/node/assert.ts6
-rw-r--r--std/node/assert_test.ts14
-rw-r--r--std/node/assertion_error_test.ts2
-rw-r--r--std/node/buffer.ts2
-rw-r--r--std/node/events_test.ts4
-rw-r--r--std/node/fs.ts6
-rw-r--r--std/node/module.ts2
-rw-r--r--std/node/module_test.ts2
-rw-r--r--std/node/os_test.ts2
-rw-r--r--std/node/process_test.ts4
-rw-r--r--std/node/querystring_test.ts2
-rw-r--r--std/node/url.ts4
-rw-r--r--std/path/_util.ts10
-rw-r--r--std/path/glob_test.ts2
-rw-r--r--std/path/parse_format_test.ts2
-rw-r--r--std/path/posix.ts4
-rw-r--r--std/path/win32.ts4
-rw-r--r--std/signal/test.ts2
-rw-r--r--std/testing/README.md2
-rw-r--r--std/testing/asserts.ts4
-rw-r--r--std/testing/asserts_test.ts12
-rw-r--r--std/testing/bench_example.ts2
-rw-r--r--std/testing/bench_test.ts6
-rw-r--r--std/uuid/test.ts2
-rw-r--r--std/ws/test.ts4
170 files changed, 281 insertions, 295 deletions
diff --git a/.dprintrc.json b/.dprintrc.json
index 4cdfdc6fa..726b2a4ad 100644
--- a/.dprintrc.json
+++ b/.dprintrc.json
@@ -30,7 +30,7 @@
"third_party"
],
"plugins": [
- "https://plugins.dprint.dev/typescript-0.29.0.wasm",
+ "https://plugins.dprint.dev/typescript-0.32.1.wasm",
"https://plugins.dprint.dev/json-0.7.0.wasm",
"https://plugins.dprint.dev/markdown-0.4.0.wasm"
]
diff --git a/Cargo.lock b/Cargo.lock
index 8e1b2452d..452f3f835 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -565,18 +565,18 @@ dependencies = [
[[package]]
name = "dprint-core"
-version = "0.28.0"
+version = "0.31.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "fab44561ffc8f70d26d6c4cc81a648ecd47dd60836abecf0599253a7b9fdbf5d"
+checksum = "a15e15225efcb6eccd138dea49bf7aa390248ab0faf650b1b8a7ad660a5778cc"
dependencies = [
"serde",
]
[[package]]
name = "dprint-plugin-typescript"
-version = "0.31.3"
+version = "0.32.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a846ca33bcd5d4adfa4c1beac0ab426ae01c7f4fcecb5542b465aef96b92fa77"
+checksum = "4b2a52a112622e8368c2e7efb0e977e8271b69862015967747d350add4298a5c"
dependencies = [
"dprint-core",
"serde",
diff --git a/cli/Cargo.toml b/cli/Cargo.toml
index 86ac0b28f..6150fa421 100644
--- a/cli/Cargo.toml
+++ b/cli/Cargo.toml
@@ -43,7 +43,7 @@ clap = "2.33.3"
dissimilar = "1.0.2"
dlopen = "0.1.8"
encoding_rs = "0.8.24"
-dprint-plugin-typescript = "0.31.3"
+dprint-plugin-typescript = "0.32.1"
filetime = "0.2.12"
http = "0.2.1"
indexmap = "1.6.0"
diff --git a/cli/tests/005_more_imports.ts b/cli/tests/005_more_imports.ts
index 52dd1df7b..0266bf46c 100644
--- a/cli/tests/005_more_imports.ts
+++ b/cli/tests/005_more_imports.ts
@@ -1,4 +1,4 @@
-import { returnsHi, returnsFoo2, printHello3 } from "./subdir/mod1.ts";
+import { printHello3, returnsFoo2, returnsHi } from "./subdir/mod1.ts";
printHello3();
diff --git a/cli/tests/bundle_im.ts b/cli/tests/bundle_im.ts
index b751aa689..c43f6294c 100644
--- a/cli/tests/bundle_im.ts
+++ b/cli/tests/bundle_im.ts
@@ -1,4 +1,4 @@
-import { returnsFoo, printHello2 } from "mod2";
+import { printHello2, returnsFoo } from "mod2";
export function returnsHi(): string {
return "Hi";
diff --git a/cli/tests/lock_check_err_with_bundle.json b/cli/tests/lock_check_err_with_bundle.json
index ae8f9dd9d..b773ed071 100644
--- a/cli/tests/lock_check_err_with_bundle.json
+++ b/cli/tests/lock_check_err_with_bundle.json
@@ -1,5 +1,5 @@
{
- "http://127.0.0.1:4545/cli/tests/subdir/mod1.ts": "f627f1649f9853adfa096241ae2defa75e4e327cbeb6af0e82a11304b3e5c8be",
+ "http://127.0.0.1:4545/cli/tests/subdir/mod1.ts": "bc699ebc05dec9a4baf2109258f03e6ec8dd5498e2f8c5469b62073b3b241657",
"http://127.0.0.1:4545/cli/tests/subdir/print_hello.ts": "fe7bbccaedb6579200a8b582f905139296402d06b1b91109d6e12c41a23125da",
"http://127.0.0.1:4545/cli/tests/subdir/subdir2/mod2.ts": "bad"
}
diff --git a/cli/tests/lock_dynamic_imports.json b/cli/tests/lock_dynamic_imports.json
index df77e179c..bfc1cf7e7 100644
--- a/cli/tests/lock_dynamic_imports.json
+++ b/cli/tests/lock_dynamic_imports.json
@@ -1,6 +1,6 @@
{
"http://127.0.0.1:4545/cli/tests/013_dynamic_import.ts": "c875f10de49bded1ad76f1709d68e6cf2c0cfb8e8e862542a3fcb4ab09257b99",
- "http://127.0.0.1:4545/cli/tests/subdir/mod1.ts": "f627f1649f9853adfa096241ae2defa75e4e327cbeb6af0e82a11304b3e5c8be",
+ "http://127.0.0.1:4545/cli/tests/subdir/mod1.ts": "bc699ebc05dec9a4baf2109258f03e6ec8dd5498e2f8c5469b62073b3b241657",
"http://127.0.0.1:4545/cli/tests/subdir/print_hello.ts": "fe7bbccaedb6579200a8b582f905139296402d06b1b91109d6e12c41a23125da",
"http://127.0.0.1:4545/cli/tests/subdir/subdir2/mod2.ts": "bad"
}
diff --git a/cli/tests/single_compile_with_reload_dyn.ts b/cli/tests/single_compile_with_reload_dyn.ts
index 52dd1df7b..0266bf46c 100644
--- a/cli/tests/single_compile_with_reload_dyn.ts
+++ b/cli/tests/single_compile_with_reload_dyn.ts
@@ -1,4 +1,4 @@
-import { returnsHi, returnsFoo2, printHello3 } from "./subdir/mod1.ts";
+import { printHello3, returnsFoo2, returnsHi } from "./subdir/mod1.ts";
printHello3();
diff --git a/cli/tests/subdir/mod1.ts b/cli/tests/subdir/mod1.ts
index 393535588..9a4b53021 100644
--- a/cli/tests/subdir/mod1.ts
+++ b/cli/tests/subdir/mod1.ts
@@ -1,4 +1,4 @@
-import { returnsFoo, printHello2 } from "./subdir2/mod2.ts";
+import { printHello2, returnsFoo } from "./subdir2/mod2.ts";
export function returnsHi(): string {
return "Hi";
diff --git a/cli/tests/unit/abort_controller_test.ts b/cli/tests/unit/abort_controller_test.ts
index ecc1abb88..d89bcdd44 100644
--- a/cli/tests/unit/abort_controller_test.ts
+++ b/cli/tests/unit/abort_controller_test.ts
@@ -1,4 +1,4 @@
-import { unitTest, assert, assertEquals } from "./test_util.ts";
+import { assert, assertEquals, unitTest } from "./test_util.ts";
unitTest(function basicAbortController() {
const controller = new AbortController();
diff --git a/cli/tests/unit/blob_test.ts b/cli/tests/unit/blob_test.ts
index b1587b6da..5bce99e18 100644
--- a/cli/tests/unit/blob_test.ts
+++ b/cli/tests/unit/blob_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals } from "./test_util.ts";
+import { assert, assertEquals, unitTest } from "./test_util.ts";
import { concat } from "../../../std/bytes/mod.ts";
import { decode } from "../../../std/encoding/utf8.ts";
diff --git a/cli/tests/unit/body_test.ts b/cli/tests/unit/body_test.ts
index d9979e703..404ae305d 100644
--- a/cli/tests/unit/body_test.ts
+++ b/cli/tests/unit/body_test.ts
@@ -1,9 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import {
- unitTest,
- assertEquals,
- assert,
-} from "./test_util.ts";
+import { assert, assertEquals, unitTest } from "./test_util.ts";
// just a hack to get a body object
// eslint-disable-next-line @typescript-eslint/no-explicit-any
diff --git a/cli/tests/unit/buffer_test.ts b/cli/tests/unit/buffer_test.ts
index 999680be7..6bea4684d 100644
--- a/cli/tests/unit/buffer_test.ts
+++ b/cli/tests/unit/buffer_test.ts
@@ -4,8 +4,8 @@
// Copyright 2009 The Go Authors. All rights reserved. BSD license.
// https://github.com/golang/go/blob/master/LICENSE
import {
- assertEquals,
assert,
+ assertEquals,
assertThrows,
assertThrowsAsync,
unitTest,
diff --git a/cli/tests/unit/build_test.ts b/cli/tests/unit/build_test.ts
index 987ed8d39..9a7e66f6c 100644
--- a/cli/tests/unit/build_test.ts
+++ b/cli/tests/unit/build_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert } from "./test_util.ts";
+import { assert, unitTest } from "./test_util.ts";
unitTest(function buildInfo(): void {
// Deno.build is injected by rollup at compile time. Here
diff --git a/cli/tests/unit/chmod_test.ts b/cli/tests/unit/chmod_test.ts
index c53fe8c8b..8fee4f5a3 100644
--- a/cli/tests/unit/chmod_test.ts
+++ b/cli/tests/unit/chmod_test.ts
@@ -1,10 +1,10 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
unitTest(
diff --git a/cli/tests/unit/chown_test.ts b/cli/tests/unit/chown_test.ts
index 93a3feec9..acdb736cb 100644
--- a/cli/tests/unit/chown_test.ts
+++ b/cli/tests/unit/chown_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assertEquals,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
// chown on Windows is noop for now, so ignore its testing on Windows
diff --git a/cli/tests/unit/copy_file_test.ts b/cli/tests/unit/copy_file_test.ts
index c45e4977b..0492c4b8c 100644
--- a/cli/tests/unit/copy_file_test.ts
+++ b/cli/tests/unit/copy_file_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assertEquals,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
function readFileString(filename: string | URL): string {
diff --git a/cli/tests/unit/custom_event_test.ts b/cli/tests/unit/custom_event_test.ts
index a8b2fcf88..72ebc75d8 100644
--- a/cli/tests/unit/custom_event_test.ts
+++ b/cli/tests/unit/custom_event_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertEquals } from "./test_util.ts";
+import { assertEquals, unitTest } from "./test_util.ts";
unitTest(function customEventInitializedWithDetail(): void {
const type = "touchstart";
diff --git a/cli/tests/unit/dir_test.ts b/cli/tests/unit/dir_test.ts
index f9f4c9456..a6e9c594a 100644
--- a/cli/tests/unit/dir_test.ts
+++ b/cli/tests/unit/dir_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals, assertThrows } from "./test_util.ts";
+import { assert, assertEquals, assertThrows, unitTest } from "./test_util.ts";
unitTest({ perms: { read: true } }, function dirCwdNotNull(): void {
assert(Deno.cwd() != null);
diff --git a/cli/tests/unit/dispatch_json_test.ts b/cli/tests/unit/dispatch_json_test.ts
index 29127a85c..ce7778e2d 100644
--- a/cli/tests/unit/dispatch_json_test.ts
+++ b/cli/tests/unit/dispatch_json_test.ts
@@ -1,8 +1,4 @@
-import {
- assertStrictEquals,
- unitTest,
- assertMatch,
-} from "./test_util.ts";
+import { assertMatch, assertStrictEquals, unitTest } from "./test_util.ts";
declare global {
// eslint-disable-next-line @typescript-eslint/no-namespace
diff --git a/cli/tests/unit/dom_exception_test.ts b/cli/tests/unit/dom_exception_test.ts
index 2eb7633e1..a93cbfebe 100644
--- a/cli/tests/unit/dom_exception_test.ts
+++ b/cli/tests/unit/dom_exception_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertEquals, assert } from "./test_util.ts";
+import { assert, assertEquals, unitTest } from "./test_util.ts";
unitTest(function testDomError() {
const de = new DOMException("foo", "bar");
diff --git a/cli/tests/unit/event_target_test.ts b/cli/tests/unit/event_target_test.ts
index 34f9019d3..10293a0e9 100644
--- a/cli/tests/unit/event_target_test.ts
+++ b/cli/tests/unit/event_target_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertEquals } from "./test_util.ts";
+import { assertEquals, unitTest } from "./test_util.ts";
unitTest(function addEventListenerTest(): void {
const document = new EventTarget();
diff --git a/cli/tests/unit/event_test.ts b/cli/tests/unit/event_test.ts
index ce3076e58..5c8766b36 100644
--- a/cli/tests/unit/event_test.ts
+++ b/cli/tests/unit/event_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertEquals, assert } from "./test_util.ts";
+import { assert, assertEquals, unitTest } from "./test_util.ts";
unitTest(function eventInitializedWithType(): void {
const type = "click";
diff --git a/cli/tests/unit/fetch_test.ts b/cli/tests/unit/fetch_test.ts
index 4bdb54d9e..64309c269 100644
--- a/cli/tests/unit/fetch_test.ts
+++ b/cli/tests/unit/fetch_test.ts
@@ -1,11 +1,11 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertThrows,
assertThrowsAsync,
fail,
+ unitTest,
} from "./test_util.ts";
unitTest({ perms: { net: true } }, async function fetchProtocolError(): Promise<
diff --git a/cli/tests/unit/file_test.ts b/cli/tests/unit/file_test.ts
index f97283b7f..5abd0e26e 100644
--- a/cli/tests/unit/file_test.ts
+++ b/cli/tests/unit/file_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals } from "./test_util.ts";
+import { assert, assertEquals, unitTest } from "./test_util.ts";
// eslint-disable-next-line @typescript-eslint/no-explicit-any
function testFirstArgument(arg1: any[], expectedSize: number): void {
diff --git a/cli/tests/unit/filereader_test.ts b/cli/tests/unit/filereader_test.ts
index 9b2cf1d12..e6fd1cab6 100644
--- a/cli/tests/unit/filereader_test.ts
+++ b/cli/tests/unit/filereader_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertEquals } from "./test_util.ts";
+import { assertEquals, unitTest } from "./test_util.ts";
unitTest(function fileReaderConstruct(): void {
const fr = new FileReader();
diff --git a/cli/tests/unit/files_test.ts b/cli/tests/unit/files_test.ts
index 873f89de0..7f0de5851 100644
--- a/cli/tests/unit/files_test.ts
+++ b/cli/tests/unit/files_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
unitTest(function filesStdioFileDescriptors(): void {
diff --git a/cli/tests/unit/filter_function_test.ts b/cli/tests/unit/filter_function_test.ts
index dd83c1dbc..2c1d9a7c8 100644
--- a/cli/tests/unit/filter_function_test.ts
+++ b/cli/tests/unit/filter_function_test.ts
@@ -1,4 +1,4 @@
-import { unitTest, assertEquals } from "./test_util.ts";
+import { assertEquals, unitTest } from "./test_util.ts";
// @ts-expect-error TypeScript (as of 3.7) does not support indexing namespaces by symbol
const { createFilterFn } = Deno[Deno.internal];
diff --git a/cli/tests/unit/form_data_test.ts b/cli/tests/unit/form_data_test.ts
index 30e9a8311..b4b998a50 100644
--- a/cli/tests/unit/form_data_test.ts
+++ b/cli/tests/unit/form_data_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertStringContains,
+ unitTest,
} from "./test_util.ts";
unitTest(function formDataHasCorrectNameProp(): void {
diff --git a/cli/tests/unit/fs_events_test.ts b/cli/tests/unit/fs_events_test.ts
index d73001187..0b30a070d 100644
--- a/cli/tests/unit/fs_events_test.ts
+++ b/cli/tests/unit/fs_events_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2019 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals, assertThrows } from "./test_util.ts";
+import { assert, assertEquals, assertThrows, unitTest } from "./test_util.ts";
// TODO(ry) Add more tests to specify format.
diff --git a/cli/tests/unit/get_random_values_test.ts b/cli/tests/unit/get_random_values_test.ts
index 69df0d44b..1e2dd654f 100644
--- a/cli/tests/unit/get_random_values_test.ts
+++ b/cli/tests/unit/get_random_values_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertNotEquals, assertStrictEquals } from "./test_util.ts";
+import { assertNotEquals, assertStrictEquals, unitTest } from "./test_util.ts";
unitTest(function getRandomValuesInt8Array(): void {
const arr = new Int8Array(32);
diff --git a/cli/tests/unit/globals_test.ts b/cli/tests/unit/globals_test.ts
index 5fc125296..6c83b1b44 100644
--- a/cli/tests/unit/globals_test.ts
+++ b/cli/tests/unit/globals_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert } from "./test_util.ts";
+import { assert, unitTest } from "./test_util.ts";
unitTest(function globalThisExists(): void {
assert(globalThis != null);
diff --git a/cli/tests/unit/headers_test.ts b/cli/tests/unit/headers_test.ts
index 5dc23355c..7ed7e1e2e 100644
--- a/cli/tests/unit/headers_test.ts
+++ b/cli/tests/unit/headers_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertStringContains,
+ unitTest,
} from "./test_util.ts";
const {
inspectArgs,
diff --git a/cli/tests/unit/internals_test.ts b/cli/tests/unit/internals_test.ts
index e59783e54..f8b8df698 100644
--- a/cli/tests/unit/internals_test.ts
+++ b/cli/tests/unit/internals_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert } from "./test_util.ts";
+import { assert, unitTest } from "./test_util.ts";
unitTest(function internalsExists(): void {
const {
diff --git a/cli/tests/unit/io_test.ts b/cli/tests/unit/io_test.ts
index 0ccd83ea2..9ca03f8f6 100644
--- a/cli/tests/unit/io_test.ts
+++ b/cli/tests/unit/io_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertEquals } from "./test_util.ts";
+import { assertEquals, unitTest } from "./test_util.ts";
const DEFAULT_BUF_SIZE = 32 * 1024;
diff --git a/cli/tests/unit/link_test.ts b/cli/tests/unit/link_test.ts
index db910ee7c..a8399fb94 100644
--- a/cli/tests/unit/link_test.ts
+++ b/cli/tests/unit/link_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals, assertThrows } from "./test_util.ts";
+import { assert, assertEquals, assertThrows, unitTest } from "./test_util.ts";
unitTest(
{ perms: { read: true, write: true } },
diff --git a/cli/tests/unit/make_temp_test.ts b/cli/tests/unit/make_temp_test.ts
index 05a422cfd..4f94ccb14 100644
--- a/cli/tests/unit/make_temp_test.ts
+++ b/cli/tests/unit/make_temp_test.ts
@@ -1,10 +1,10 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
unitTest({ perms: { write: true } }, function makeTempDirSyncSuccess(): void {
diff --git a/cli/tests/unit/metrics_test.ts b/cli/tests/unit/metrics_test.ts
index 48ddf30d7..0070ca7df 100644
--- a/cli/tests/unit/metrics_test.ts
+++ b/cli/tests/unit/metrics_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert } from "./test_util.ts";
+import { assert, unitTest } from "./test_util.ts";
unitTest(async function metrics(): Promise<void> {
const m1 = Deno.metrics();
diff --git a/cli/tests/unit/mkdir_test.ts b/cli/tests/unit/mkdir_test.ts
index 449c79747..9ab6dc4d2 100644
--- a/cli/tests/unit/mkdir_test.ts
+++ b/cli/tests/unit/mkdir_test.ts
@@ -1,10 +1,10 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
function assertDirectory(path: string, mode?: number): void {
diff --git a/cli/tests/unit/net_test.ts b/cli/tests/unit/net_test.ts
index 793082ced..2c6134318 100644
--- a/cli/tests/unit/net_test.ts
+++ b/cli/tests/unit/net_test.ts
@@ -1,12 +1,12 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
+ assertNotEquals,
assertThrows,
assertThrowsAsync,
createResolvable,
- assertNotEquals,
+ unitTest,
} from "./test_util.ts";
unitTest({ perms: { net: true } }, function netTcpListenClose(): void {
diff --git a/cli/tests/unit/path_from_url_test.ts b/cli/tests/unit/path_from_url_test.ts
index 047451d48..d086ce1dc 100644
--- a/cli/tests/unit/path_from_url_test.ts
+++ b/cli/tests/unit/path_from_url_test.ts
@@ -1,4 +1,4 @@
-import { assertThrows, assertEquals, unitTest } from "./test_util.ts";
+import { assertEquals, assertThrows, unitTest } from "./test_util.ts";
// @ts-expect-error TypeScript (as of 3.7) does not support indexing namespaces by symbol
const { pathFromURL } = Deno[Deno.internal];
diff --git a/cli/tests/unit/performance_test.ts b/cli/tests/unit/performance_test.ts
index 7b2fa5cef..2a25887db 100644
--- a/cli/tests/unit/performance_test.ts
+++ b/cli/tests/unit/performance_test.ts
@@ -1,10 +1,10 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertThrows,
createResolvable,
+ unitTest,
} from "./test_util.ts";
unitTest({ perms: { hrtime: false } }, async function performanceNow(): Promise<
diff --git a/cli/tests/unit/permissions_test.ts b/cli/tests/unit/permissions_test.ts
index 21fa1d27b..ed6298ee8 100644
--- a/cli/tests/unit/permissions_test.ts
+++ b/cli/tests/unit/permissions_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertThrows, assertThrowsAsync } from "./test_util.ts";
+import { assertThrows, assertThrowsAsync, unitTest } from "./test_util.ts";
unitTest(async function permissionInvalidName(): Promise<void> {
await assertThrowsAsync(async () => {
diff --git a/cli/tests/unit/process_test.ts b/cli/tests/unit/process_test.ts
index 76b755295..ef3f5023e 100644
--- a/cli/tests/unit/process_test.ts
+++ b/cli/tests/unit/process_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
assert,
- assertThrows,
assertEquals,
assertStringContains,
+ assertThrows,
unitTest,
} from "./test_util.ts";
diff --git a/cli/tests/unit/progressevent_test.ts b/cli/tests/unit/progressevent_test.ts
index 4f852e458..0080291f0 100644
--- a/cli/tests/unit/progressevent_test.ts
+++ b/cli/tests/unit/progressevent_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertEquals } from "./test_util.ts";
+import { assertEquals, unitTest } from "./test_util.ts";
unitTest(function progressEventConstruct(): void {
const progressEventDefs = new ProgressEvent("progressEventType", {});
diff --git a/cli/tests/unit/read_dir_test.ts b/cli/tests/unit/read_dir_test.ts
index 97c45dac3..0a1fe76d7 100644
--- a/cli/tests/unit/read_dir_test.ts
+++ b/cli/tests/unit/read_dir_test.ts
@@ -1,11 +1,11 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertThrows,
assertThrowsAsync,
pathToAbsoluteFileUrl,
+ unitTest,
} from "./test_util.ts";
function assertSameContent(files: Deno.DirEntry[]): void {
diff --git a/cli/tests/unit/read_file_test.ts b/cli/tests/unit/read_file_test.ts
index 06141002d..2e9def581 100644
--- a/cli/tests/unit/read_file_test.ts
+++ b/cli/tests/unit/read_file_test.ts
@@ -1,11 +1,11 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertThrows,
assertThrowsAsync,
pathToAbsoluteFileUrl,
+ unitTest,
} from "./test_util.ts";
unitTest({ perms: { read: true } }, function readFileSyncSuccess(): void {
diff --git a/cli/tests/unit/read_link_test.ts b/cli/tests/unit/read_link_test.ts
index a4baeb792..0e8390f6a 100644
--- a/cli/tests/unit/read_link_test.ts
+++ b/cli/tests/unit/read_link_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assertEquals,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
unitTest(
diff --git a/cli/tests/unit/read_text_file_test.ts b/cli/tests/unit/read_text_file_test.ts
index 98275f781..dc6a901bb 100644
--- a/cli/tests/unit/read_text_file_test.ts
+++ b/cli/tests/unit/read_text_file_test.ts
@@ -1,10 +1,10 @@
import {
- unitTest,
assert,
assertEquals,
assertThrows,
assertThrowsAsync,
pathToAbsoluteFileUrl,
+ unitTest,
} from "./test_util.ts";
unitTest({ perms: { read: true } }, function readTextFileSyncSuccess(): void {
diff --git a/cli/tests/unit/real_path_test.ts b/cli/tests/unit/real_path_test.ts
index 1036f6132..d00aed0dd 100644
--- a/cli/tests/unit/real_path_test.ts
+++ b/cli/tests/unit/real_path_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
unitTest({ perms: { read: true } }, function realPathSyncSuccess(): void {
diff --git a/cli/tests/unit/remove_test.ts b/cli/tests/unit/remove_test.ts
index 14c960da5..add1a9648 100644
--- a/cli/tests/unit/remove_test.ts
+++ b/cli/tests/unit/remove_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
const REMOVE_METHODS = ["remove", "removeSync"] as const;
diff --git a/cli/tests/unit/rename_test.ts b/cli/tests/unit/rename_test.ts
index dfde8dc05..57c3a4cee 100644
--- a/cli/tests/unit/rename_test.ts
+++ b/cli/tests/unit/rename_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals, assertThrows } from "./test_util.ts";
+import { assert, assertEquals, assertThrows, unitTest } from "./test_util.ts";
function assertMissing(path: string): void {
let caughtErr = false;
diff --git a/cli/tests/unit/request_test.ts b/cli/tests/unit/request_test.ts
index 24f5b6d82..c8b8377d4 100644
--- a/cli/tests/unit/request_test.ts
+++ b/cli/tests/unit/request_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals } from "./test_util.ts";
+import { assert, assertEquals, unitTest } from "./test_util.ts";
unitTest(function fromInit(): void {
const req = new Request("https://example.com", {
diff --git a/cli/tests/unit/resources_test.ts b/cli/tests/unit/resources_test.ts
index 4e4288ff9..9c2aec91a 100644
--- a/cli/tests/unit/resources_test.ts
+++ b/cli/tests/unit/resources_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertEquals, assert, assertThrows } from "./test_util.ts";
+import { assert, assertEquals, assertThrows, unitTest } from "./test_util.ts";
unitTest(function resourcesCloseBadArgs(): void {
assertThrows(() => {
diff --git a/cli/tests/unit/response_test.ts b/cli/tests/unit/response_test.ts
index 13a8570d7..163a92835 100644
--- a/cli/tests/unit/response_test.ts
+++ b/cli/tests/unit/response_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals } from "./test_util.ts";
+import { assert, assertEquals, unitTest } from "./test_util.ts";
unitTest(async function responseText() {
const response = new Response("hello world");
diff --git a/cli/tests/unit/signal_test.ts b/cli/tests/unit/signal_test.ts
index 98eac6e0b..2ea1e865f 100644
--- a/cli/tests/unit/signal_test.ts
+++ b/cli/tests/unit/signal_test.ts
@@ -1,10 +1,10 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertThrows,
createResolvable,
+ unitTest,
} from "./test_util.ts";
function defer(n: number): Promise<void> {
diff --git a/cli/tests/unit/stat_test.ts b/cli/tests/unit/stat_test.ts
index a7911b9c9..d351a188e 100644
--- a/cli/tests/unit/stat_test.ts
+++ b/cli/tests/unit/stat_test.ts
@@ -1,11 +1,11 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertThrows,
assertThrowsAsync,
pathToAbsoluteFileUrl,
+ unitTest,
} from "./test_util.ts";
unitTest({ perms: { read: true } }, function fstatSyncSuccess(): void {
diff --git a/cli/tests/unit/stdio_test.ts b/cli/tests/unit/stdio_test.ts
index 244ebcd47..d5a7304a7 100644
--- a/cli/tests/unit/stdio_test.ts
+++ b/cli/tests/unit/stdio_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertEquals } from "./test_util.ts";
+import { assertEquals, unitTest } from "./test_util.ts";
unitTest(async function stdioStdinRead() {
const nread = await Deno.stdin.read(new Uint8Array(0));
diff --git a/cli/tests/unit/streams_internal_test.ts b/cli/tests/unit/streams_internal_test.ts
index caeab431d..096fcef3c 100644
--- a/cli/tests/unit/streams_internal_test.ts
+++ b/cli/tests/unit/streams_internal_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertThrows } from "./test_util.ts";
+import { assertThrows, unitTest } from "./test_util.ts";
unitTest(function streamReadableHwmError() {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
diff --git a/cli/tests/unit/streams_piping_test.ts b/cli/tests/unit/streams_piping_test.ts
index 0696021cb..959d2e478 100644
--- a/cli/tests/unit/streams_piping_test.ts
+++ b/cli/tests/unit/streams_piping_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals } from "./test_util.ts";
+import { assert, assertEquals, unitTest } from "./test_util.ts";
import { assertThrowsAsync } from "../../../std/testing/asserts.ts";
unitTest(function streamPipeLocks() {
diff --git a/cli/tests/unit/streams_transform_test.ts b/cli/tests/unit/streams_transform_test.ts
index fa321daf2..b07fccffb 100644
--- a/cli/tests/unit/streams_transform_test.ts
+++ b/cli/tests/unit/streams_transform_test.ts
@@ -1,10 +1,10 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assert,
assertEquals,
assertNotEquals,
assertThrows,
+ unitTest,
} from "./test_util.ts";
function delay(seconds: number): Promise<void> {
diff --git a/cli/tests/unit/streams_writable_test.ts b/cli/tests/unit/streams_writable_test.ts
index a06b15c7e..e712ee83c 100644
--- a/cli/tests/unit/streams_writable_test.ts
+++ b/cli/tests/unit/streams_writable_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals, assertThrows } from "./test_util.ts";
+import { assert, assertEquals, assertThrows, unitTest } from "./test_util.ts";
unitTest(function writableStreamDesiredSizeOnReleasedWriter() {
const ws = new WritableStream();
diff --git a/cli/tests/unit/symlink_test.ts b/cli/tests/unit/symlink_test.ts
index b7babc88a..27cbdcdca 100644
--- a/cli/tests/unit/symlink_test.ts
+++ b/cli/tests/unit/symlink_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertThrows } from "./test_util.ts";
+import { assert, assertThrows, unitTest } from "./test_util.ts";
unitTest(
{ perms: { read: true, write: true } },
diff --git a/cli/tests/unit/sync_test.ts b/cli/tests/unit/sync_test.ts
index d16ab60d4..e062c3f16 100644
--- a/cli/tests/unit/sync_test.ts
+++ b/cli/tests/unit/sync_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertEquals } from "./test_util.ts";
+import { assertEquals, unitTest } from "./test_util.ts";
unitTest(
{ perms: { read: true, write: true } },
diff --git a/cli/tests/unit/test_util.ts b/cli/tests/unit/test_util.ts
index 865b6e061..746eb2c17 100644
--- a/cli/tests/unit/test_util.ts
+++ b/cli/tests/unit/test_util.ts
@@ -6,15 +6,15 @@ export { colors };
import { resolve } from "../../../std/path/mod.ts";
export {
assert,
- assertThrows,
- assertThrowsAsync,
assertEquals,
assertMatch,
assertNotEquals,
assertStrictEquals,
assertStringContains,
- unreachable,
+ assertThrows,
+ assertThrowsAsync,
fail,
+ unreachable,
} from "../../../std/testing/asserts.ts";
export { readLines } from "../../../std/io/bufio.ts";
export { parse as parseArgs } from "../../../std/flags/mod.ts";
diff --git a/cli/tests/unit/text_encoding_test.ts b/cli/tests/unit/text_encoding_test.ts
index e990f1284..23799fba3 100644
--- a/cli/tests/unit/text_encoding_test.ts
+++ b/cli/tests/unit/text_encoding_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals, assertThrows } from "./test_util.ts";
+import { assert, assertEquals, assertThrows, unitTest } from "./test_util.ts";
unitTest(function btoaSuccess(): void {
const text = "hello world";
diff --git a/cli/tests/unit/timers_test.ts b/cli/tests/unit/timers_test.ts
index 036900f7c..b304d8946 100644
--- a/cli/tests/unit/timers_test.ts
+++ b/cli/tests/unit/timers_test.ts
@@ -1,10 +1,10 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
- createResolvable,
assert,
assertEquals,
assertNotEquals,
+ createResolvable,
+ unitTest,
} from "./test_util.ts";
function waitForMs(ms: number): Promise<number> {
diff --git a/cli/tests/unit/tls_test.ts b/cli/tests/unit/tls_test.ts
index ed7466a2c..058abf5d7 100644
--- a/cli/tests/unit/tls_test.ts
+++ b/cli/tests/unit/tls_test.ts
@@ -7,7 +7,7 @@ import {
createResolvable,
unitTest,
} from "./test_util.ts";
-import { BufWriter, BufReader } from "../../../std/io/bufio.ts";
+import { BufReader, BufWriter } from "../../../std/io/bufio.ts";
import { TextProtoReader } from "../../../std/textproto/mod.ts";
const encoder = new TextEncoder();
diff --git a/cli/tests/unit/truncate_test.ts b/cli/tests/unit/truncate_test.ts
index db2cdc4be..b603ebaea 100644
--- a/cli/tests/unit/truncate_test.ts
+++ b/cli/tests/unit/truncate_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assertEquals,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
unitTest(
diff --git a/cli/tests/unit/tty_test.ts b/cli/tests/unit/tty_test.ts
index 7e9873791..c32bfa337 100644
--- a/cli/tests/unit/tty_test.ts
+++ b/cli/tests/unit/tty_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertThrows } from "./test_util.ts";
+import { assert, assertThrows, unitTest } from "./test_util.ts";
// Note tests for Deno.setRaw is in integration tests.
diff --git a/cli/tests/unit/umask_test.ts b/cli/tests/unit/umask_test.ts
index 6fe51254d..e84401d69 100644
--- a/cli/tests/unit/umask_test.ts
+++ b/cli/tests/unit/umask_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assertEquals } from "./test_util.ts";
+import { assertEquals, unitTest } from "./test_util.ts";
unitTest(
{
diff --git a/cli/tests/unit/unit_test_runner.ts b/cli/tests/unit/unit_test_runner.ts
index 815a501f2..07793085a 100755
--- a/cli/tests/unit/unit_test_runner.ts
+++ b/cli/tests/unit/unit_test_runner.ts
@@ -2,14 +2,14 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import "./unit_tests.ts";
import {
- REGISTERED_UNIT_TESTS,
colors,
- readLines,
+ fmtPerms,
+ parseArgs,
permissionCombinations,
Permissions,
+ readLines,
+ REGISTERED_UNIT_TESTS,
registerUnitTests,
- fmtPerms,
- parseArgs,
reportToConn,
} from "./test_util.ts";
diff --git a/cli/tests/unit/url_search_params_test.ts b/cli/tests/unit/url_search_params_test.ts
index 5e1d2afb5..96b524265 100644
--- a/cli/tests/unit/url_search_params_test.ts
+++ b/cli/tests/unit/url_search_params_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals } from "./test_util.ts";
+import { assert, assertEquals, unitTest } from "./test_util.ts";
unitTest(function urlSearchParamsWithMultipleSpaces(): void {
const init = { str: "this string has spaces in it" };
diff --git a/cli/tests/unit/url_test.ts b/cli/tests/unit/url_test.ts
index bf367df76..e9632c7de 100644
--- a/cli/tests/unit/url_test.ts
+++ b/cli/tests/unit/url_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { unitTest, assert, assertEquals, assertThrows } from "./test_util.ts";
+import { assert, assertEquals, assertThrows, unitTest } from "./test_util.ts";
unitTest(function urlParsing(): void {
const url = new URL(
diff --git a/cli/tests/unit/utime_test.ts b/cli/tests/unit/utime_test.ts
index e64d1d892..9045755dc 100644
--- a/cli/tests/unit/utime_test.ts
+++ b/cli/tests/unit/utime_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assertEquals,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
unitTest(
diff --git a/cli/tests/unit/version_test.ts b/cli/tests/unit/version_test.ts
index 0417b27de..f581afd83 100644
--- a/cli/tests/unit/version_test.ts
+++ b/cli/tests/unit/version_test.ts
@@ -1,4 +1,4 @@
-import { unitTest, assert } from "./test_util.ts";
+import { assert, unitTest } from "./test_util.ts";
unitTest(function version(): void {
const pattern = /^\d+\.\d+\.\d+/;
diff --git a/cli/tests/unit/write_file_test.ts b/cli/tests/unit/write_file_test.ts
index a48333b9d..b66be3623 100644
--- a/cli/tests/unit/write_file_test.ts
+++ b/cli/tests/unit/write_file_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- unitTest,
assertEquals,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
unitTest(
diff --git a/cli/tests/unit/write_text_file_test.ts b/cli/tests/unit/write_text_file_test.ts
index 42c72de7a..f41f8f663 100644
--- a/cli/tests/unit/write_text_file_test.ts
+++ b/cli/tests/unit/write_text_file_test.ts
@@ -1,9 +1,9 @@
import {
- unitTest,
assert,
assertEquals,
assertThrows,
assertThrowsAsync,
+ unitTest,
} from "./test_util.ts";
unitTest(
diff --git a/docs/examples/import_export.md b/docs/examples/import_export.md
index f2cd78222..e036f874d 100644
--- a/docs/examples/import_export.md
+++ b/docs/examples/import_export.md
@@ -20,10 +20,7 @@ specified in full. You may not omit the file extension and there is no special
handling of `index.js`.
```js
-import {
- add,
- multiply,
-} from "./arithmetic.ts";
+import { add, multiply } from "./arithmetic.ts";
```
Dependencies are also imported directly, there is no package management
diff --git a/docs/examples/manage_dependencies.md b/docs/examples/manage_dependencies.md
index 44b3082f8..357eccb4b 100644
--- a/docs/examples/manage_dependencies.md
+++ b/docs/examples/manage_dependencies.md
@@ -55,10 +55,7 @@ local `deps.ts` module.
* example.ts
*/
-import {
- add,
- multiply,
-} from "./deps.ts";
+import { add, multiply } from "./deps.ts";
function totalCost(outbound: number, inbound: number, tax: number): number {
return multiply(add(outbound, inbound), tax);
diff --git a/docs/testing.md b/docs/testing.md
index f92f5fadd..fcf6a3c1d 100644
--- a/docs/testing.md
+++ b/docs/testing.md
@@ -32,8 +32,8 @@ https://deno.land/std@$STD_VERSION/testing#usage to make testing easier:
```ts
import {
- assertEquals,
assertArrayContains,
+ assertEquals,
} from "https://deno.land/std@$STD_VERSION/testing/asserts.ts";
Deno.test("hello world", () => {
diff --git a/docs/tools/bundler.md b/docs/tools/bundler.md
index 292adb5f4..e8044facf 100644
--- a/docs/tools/bundler.md
+++ b/docs/tools/bundler.md
@@ -31,7 +31,7 @@ export const bar = "bar";
It could be imported like this:
```ts
-import { foo, bar } from "./lib.bundle.js";
+import { bar, foo } from "./lib.bundle.js";
```
Bundles can also be loaded in the web browser. The bundle is a self-contained ES
diff --git a/std/_util/deep_assign_test.ts b/std/_util/deep_assign_test.ts
index 14e81348d..1372c25e9 100644
--- a/std/_util/deep_assign_test.ts
+++ b/std/_util/deep_assign_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { assertEquals, assert } from "../testing/asserts.ts";
+import { assert, assertEquals } from "../testing/asserts.ts";
import { deepAssign } from "./deep_assign.ts";
Deno.test("deepAssignTest", function (): void {
diff --git a/std/archive/tar_test.ts b/std/archive/tar_test.ts
index 00ecbbf45..ff1ada4d5 100644
--- a/std/archive/tar_test.ts
+++ b/std/archive/tar_test.ts
@@ -9,9 +9,9 @@
* **to run this test**
* deno run --allow-read archive/tar_test.ts
*/
-import { assertEquals, assert } from "../testing/asserts.ts";
+import { assert, assertEquals } from "../testing/asserts.ts";
-import { resolve, dirname, fromFileUrl } from "../path/mod.ts";
+import { dirname, fromFileUrl, resolve } from "../path/mod.ts";
import { Tar, Untar } from "./tar.ts";
const moduleDir = dirname(fromFileUrl(import.meta.url));
diff --git a/std/bytes/test.ts b/std/bytes/test.ts
index 6dffad17f..46f819193 100644
--- a/std/bytes/test.ts
+++ b/std/bytes/test.ts
@@ -1,18 +1,18 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
+ concat,
+ contains,
+ copyBytes,
+ equal,
findIndex,
findLastIndex,
- equal,
hasPrefix,
hasSuffix,
repeat,
- concat,
- contains,
- copyBytes,
} from "./mod.ts";
-import { assertEquals, assertThrows, assert } from "../testing/asserts.ts";
-import { encode, decode } from "../encoding/utf8.ts";
+import { assert, assertEquals, assertThrows } from "../testing/asserts.ts";
+import { decode, encode } from "../encoding/utf8.ts";
Deno.test("[bytes] findIndex1", () => {
const i = findIndex(
diff --git a/std/datetime/formatter.ts b/std/datetime/formatter.ts
index 6f11090f0..b27a3824e 100644
--- a/std/datetime/formatter.ts
+++ b/std/datetime/formatter.ts
@@ -1,11 +1,11 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
CallbackResult,
+ ReceiverResult,
Rule,
TestFunction,
TestResult,
Tokenizer,
- ReceiverResult,
} from "./tokenizer.ts";
function digits(value: string | number, count = 2): string {
diff --git a/std/encoding/README.md b/std/encoding/README.md
index fa9753777..21797a451 100644
--- a/std/encoding/README.md
+++ b/std/encoding/README.md
@@ -308,7 +308,7 @@ for Deno
decodes the given RFC4648 base32 representation to a `Uint8Array`.
```ts
-import { encode, decode } from "https://deno.land/std/encoding/base32.ts";
+import { decode, encode } from "https://deno.land/std/encoding/base32.ts";
const b32Repr = "RC2E6GA=";
@@ -330,7 +330,7 @@ Ascii85/base85 encoder and decoder with support for multiple standards
decodes the given ascii85 representation to a `Uint8Array`.
```ts
-import { encode, decode } from "https://deno.land/std/encoding/ascii85.ts";
+import { decode, encode } from "https://deno.land/std/encoding/ascii85.ts";
const a85Repr = "LpTqp";
@@ -359,7 +359,7 @@ supported by other encodings.)
encoding examples:
```ts
-import { encode, decode } from "https://deno.land/std/encoding/ascii85.ts";
+import { decode, encode } from "https://deno.land/std/encoding/ascii85.ts";
const binaryData = new Uint8Array([136, 180, 79, 24]);
console.log(encode(binaryData));
// => LpTqp
diff --git a/std/encoding/_yaml/dumper/dumper_state.ts b/std/encoding/_yaml/dumper/dumper_state.ts
index 63b04983e..31fe86f56 100644
--- a/std/encoding/_yaml/dumper/dumper_state.ts
+++ b/std/encoding/_yaml/dumper/dumper_state.ts
@@ -6,7 +6,7 @@
import type { Schema, SchemaDefinition } from "../schema.ts";
import { State } from "../state.ts";
import type { StyleVariant, Type } from "../type.ts";
-import type { ArrayObject, Any } from "../utils.ts";
+import type { Any, ArrayObject } from "../utils.ts";
const _hasOwnProperty = Object.prototype.hasOwnProperty;
diff --git a/std/encoding/_yaml/schema.ts b/std/encoding/_yaml/schema.ts
index b955e5df8..dfb8589c1 100644
--- a/std/encoding/_yaml/schema.ts
+++ b/std/encoding/_yaml/schema.ts
@@ -5,7 +5,7 @@
import { YAMLError } from "./error.ts";
import type { KindType, Type } from "./type.ts";
-import type { ArrayObject, Any } from "./utils.ts";
+import type { Any, ArrayObject } from "./utils.ts";
function compileList(
schema: Schema,
diff --git a/std/encoding/_yaml/type.ts b/std/encoding/_yaml/type.ts
index 89a91106b..f6ce9591c 100644
--- a/std/encoding/_yaml/type.ts
+++ b/std/encoding/_yaml/type.ts
@@ -3,7 +3,7 @@
// Copyright 2011-2015 by Vitaly Puzrin. All rights reserved. MIT license.
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import type { ArrayObject, Any } from "./utils.ts";
+import type { Any, ArrayObject } from "./utils.ts";
export type KindType = "sequence" | "scalar" | "mapping";
export type StyleVariant = "lowercase" | "uppercase" | "camelcase" | "decimal";
diff --git a/std/encoding/_yaml/type/float.ts b/std/encoding/_yaml/type/float.ts
index 6d59ed9ed..93635ba25 100644
--- a/std/encoding/_yaml/type/float.ts
+++ b/std/encoding/_yaml/type/float.ts
@@ -4,7 +4,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { StyleVariant, Type } from "../type.ts";
-import { isNegativeZero, Any } from "../utils.ts";
+import { Any, isNegativeZero } from "../utils.ts";
const YAML_FLOAT_PATTERN = new RegExp(
// 2.5e4, 2.5 and integers
diff --git a/std/encoding/_yaml/type/int.ts b/std/encoding/_yaml/type/int.ts
index 6a86aafe9..5186140e4 100644
--- a/std/encoding/_yaml/type/int.ts
+++ b/std/encoding/_yaml/type/int.ts
@@ -4,7 +4,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { Type } from "../type.ts";
-import { isNegativeZero, Any } from "../utils.ts";
+import { Any, isNegativeZero } from "../utils.ts";
function isHexCode(c: number): boolean {
return (
diff --git a/std/encoding/ascii85_test.ts b/std/encoding/ascii85_test.ts
index 02af70964..cea939faf 100644
--- a/std/encoding/ascii85_test.ts
+++ b/std/encoding/ascii85_test.ts
@@ -1,6 +1,6 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { assertEquals } from "../testing/asserts.ts";
-import { encode, decode, Ascii85Standard } from "./ascii85.ts";
+import { Ascii85Standard, decode, encode } from "./ascii85.ts";
type TestCases = Partial<{ [index in Ascii85Standard]: string[][] }>;
const utf8encoder = new TextEncoder();
const testCasesNoDelimeter: TestCases = {
diff --git a/std/encoding/base32_test.ts b/std/encoding/base32_test.ts
index cfefe54d7..a604bf323 100644
--- a/std/encoding/base32_test.ts
+++ b/std/encoding/base32_test.ts
@@ -1,8 +1,8 @@
// Test cases copied from https://github.com/LinusU/base32-encode/blob/master/test.js
// Copyright (c) 2016-2017 Linus Unnebäck. MIT license.
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { assertEquals, assert } from "../testing/asserts.ts";
-import { encode, decode } from "./base32.ts";
+import { assert, assertEquals } from "../testing/asserts.ts";
+import { decode, encode } from "./base32.ts";
// Lifted from https://stackoverflow.com/questions/38987784
const fromHexString = (hexString: string): Uint8Array =>
diff --git a/std/encoding/base64_test.ts b/std/encoding/base64_test.ts
index 9e549c698..5fe89410b 100644
--- a/std/encoding/base64_test.ts
+++ b/std/encoding/base64_test.ts
@@ -1,6 +1,6 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { assertEquals } from "../testing/asserts.ts";
-import { encode, decode, decodeString } from "./base64.ts";
+import { decode, decodeString, encode } from "./base64.ts";
const testsetString = [
["", ""],
diff --git a/std/encoding/base64url_test.ts b/std/encoding/base64url_test.ts
index 9a864a87c..59d67240f 100644
--- a/std/encoding/base64url_test.ts
+++ b/std/encoding/base64url_test.ts
@@ -1,6 +1,6 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { assertEquals } from "../testing/asserts.ts";
-import { encode, decode } from "./base64url.ts";
+import { decode, encode } from "./base64url.ts";
const testsetString = [
["", ""],
diff --git a/std/encoding/binary_test.ts b/std/encoding/binary_test.ts
index 89a5b8c8e..a4e3cb144 100644
--- a/std/encoding/binary_test.ts
+++ b/std/encoding/binary_test.ts
@@ -9,11 +9,11 @@ import {
readVarnum,
sizeof,
varbig,
+ varbigBytes,
varnum,
+ varnumBytes,
writeVarbig,
writeVarnum,
- varbigBytes,
- varnumBytes,
} from "./binary.ts";
Deno.test("testGetNBytes", async function (): Promise<void> {
diff --git a/std/encoding/csv_test.ts b/std/encoding/csv_test.ts
index aab9e86b1..1a2d892cc 100644
--- a/std/encoding/csv_test.ts
+++ b/std/encoding/csv_test.ts
@@ -6,13 +6,13 @@
import { assertEquals, assertThrowsAsync } from "../testing/asserts.ts";
import {
- readMatrix,
- parse,
ERR_BARE_QUOTE,
- ERR_QUOTE,
- ERR_INVALID_DELIM,
ERR_FIELD_COUNT,
+ ERR_INVALID_DELIM,
+ ERR_QUOTE,
+ parse,
ParseError,
+ readMatrix,
} from "./csv.ts";
import { StringReader } from "../io/readers.ts";
import { BufReader } from "../io/bufio.ts";
diff --git a/std/encoding/hex_test.ts b/std/encoding/hex_test.ts
index 0cf39ad2e..d1a4002c6 100644
--- a/std/encoding/hex_test.ts
+++ b/std/encoding/hex_test.ts
@@ -7,14 +7,14 @@
import { assertEquals, assertThrows } from "../testing/asserts.ts";
import {
- encodedLen,
- encode,
- encodeToString,
- decodedLen,
decode,
+ decodedLen,
decodeString,
- errLength,
+ encode,
+ encodedLen,
+ encodeToString,
errInvalidByte,
+ errLength,
} from "./hex.ts";
function toByte(s: string): number {
diff --git a/std/examples/chat/server.ts b/std/examples/chat/server.ts
index 238d61fff..ce2e196f3 100644
--- a/std/examples/chat/server.ts
+++ b/std/examples/chat/server.ts
@@ -1,10 +1,10 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { listenAndServe } from "../../http/server.ts";
import {
- acceptWebSocket,
acceptable,
- WebSocket,
+ acceptWebSocket,
isWebSocketCloseEvent,
+ WebSocket,
} from "../../ws/mod.ts";
import { fromFileUrl } from "../../path/mod.ts";
diff --git a/std/examples/chat/server_test.ts b/std/examples/chat/server_test.ts
index 336b188e9..5e30b4ba7 100644
--- a/std/examples/chat/server_test.ts
+++ b/std/examples/chat/server_test.ts
@@ -3,7 +3,7 @@ import { assert, assertEquals } from "../../testing/asserts.ts";
import { TextProtoReader } from "../../textproto/mod.ts";
import { BufReader } from "../../io/bufio.ts";
import { delay } from "../../async/delay.ts";
-import { resolve, dirname, fromFileUrl } from "../../path/mod.ts";
+import { dirname, fromFileUrl, resolve } from "../../path/mod.ts";
const moduleDir = resolve(dirname(fromFileUrl(import.meta.url)));
diff --git a/std/examples/colors.ts b/std/examples/colors.ts
index c4cab7e78..5c0f1ac77 100644
--- a/std/examples/colors.ts
+++ b/std/examples/colors.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { bgBlue, red, bold, italic } from "../fmt/colors.ts";
+import { bgBlue, bold, italic, red } from "../fmt/colors.ts";
if (import.meta.main) {
console.log(bgBlue(italic(red(bold("Hello world!")))));
diff --git a/std/examples/echo_server_test.ts b/std/examples/echo_server_test.ts
index 1a5286a0e..5334cb610 100644
--- a/std/examples/echo_server_test.ts
+++ b/std/examples/echo_server_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { assertStrictEquals, assertNotEquals } from "../testing/asserts.ts";
+import { assertNotEquals, assertStrictEquals } from "../testing/asserts.ts";
import { BufReader, ReadLineResult } from "../io/bufio.ts";
import { dirname, fromFileUrl } from "../path/mod.ts";
diff --git a/std/examples/test.ts b/std/examples/test.ts
index a8ac8c74e..a7b09d5bc 100644
--- a/std/examples/test.ts
+++ b/std/examples/test.ts
@@ -1,6 +1,6 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { assertEquals } from "../testing/asserts.ts";
-import { dirname, relative, resolve, fromFileUrl } from "../path/mod.ts";
+import { dirname, fromFileUrl, relative, resolve } from "../path/mod.ts";
const moduleDir = dirname(fromFileUrl(import.meta.url));
diff --git a/std/examples/xeval_test.ts b/std/examples/xeval_test.ts
index 93e664dde..6ace4f532 100644
--- a/std/examples/xeval_test.ts
+++ b/std/examples/xeval_test.ts
@@ -3,9 +3,9 @@ import { xeval } from "./xeval.ts";
import { StringReader } from "../io/readers.ts";
import { decode, encode } from "../encoding/utf8.ts";
import {
+ assert,
assertEquals,
assertStringContains,
- assert,
} from "../testing/asserts.ts";
import { dirname, fromFileUrl } from "../path/mod.ts";
diff --git a/std/fs/_util_test.ts b/std/fs/_util_test.ts
index b5fdfe40b..9a24caaf0 100644
--- a/std/fs/_util_test.ts
+++ b/std/fs/_util_test.ts
@@ -2,7 +2,7 @@
import { assertEquals } from "../testing/asserts.ts";
import * as path from "../path/mod.ts";
-import { isSubdir, getFileInfoType, PathType } from "./_util.ts";
+import { getFileInfoType, isSubdir, PathType } from "./_util.ts";
import { ensureFileSync } from "./ensure_file.ts";
import { ensureDirSync } from "./ensure_dir.ts";
diff --git a/std/fs/copy.ts b/std/fs/copy.ts
index b1b340354..ed4493da0 100644
--- a/std/fs/copy.ts
+++ b/std/fs/copy.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import * as path from "../path/mod.ts";
import { ensureDir, ensureDirSync } from "./ensure_dir.ts";
-import { isSubdir, getFileInfoType } from "./_util.ts";
+import { getFileInfoType, isSubdir } from "./_util.ts";
import { assert } from "../_util/assert.ts";
const isWindows = Deno.build.os === "windows";
diff --git a/std/fs/copy_test.ts b/std/fs/copy_test.ts
index db9451200..859239d10 100644
--- a/std/fs/copy_test.ts
+++ b/std/fs/copy_test.ts
@@ -1,9 +1,9 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
+ assert,
assertEquals,
assertThrows,
assertThrowsAsync,
- assert,
} from "../testing/asserts.ts";
import * as path from "../path/mod.ts";
import { copy, copySync } from "./copy.ts";
diff --git a/std/fs/eol_test.ts b/std/fs/eol_test.ts
index 35b3e0d9a..dd427d219 100644
--- a/std/fs/eol_test.ts
+++ b/std/fs/eol_test.ts
@@ -1,6 +1,6 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { assertEquals } from "../testing/asserts.ts";
-import { format, detect, EOL } from "./eol.ts";
+import { detect, EOL, format } from "./eol.ts";
const CRLFinput = "deno\r\nis not\r\nnode";
const Mixedinput = "deno\nis not\r\nnode";
diff --git a/std/fs/expand_glob.ts b/std/fs/expand_glob.ts
index c57ddef45..72907e157 100644
--- a/std/fs/expand_glob.ts
+++ b/std/fs/expand_glob.ts
@@ -1,18 +1,18 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
GlobOptions,
- SEP_PATTERN,
globToRegExp,
isAbsolute,
isGlob,
joinGlobs,
normalize,
+ SEP_PATTERN,
} from "../path/mod.ts";
import {
- WalkEntry,
_createWalkEntry,
_createWalkEntrySync,
walk,
+ WalkEntry,
walkSync,
} from "./walk.ts";
import { assert } from "../_util/assert.ts";
diff --git a/std/fs/expand_glob_test.ts b/std/fs/expand_glob_test.ts
index 49c7bf143..39235906b 100644
--- a/std/fs/expand_glob_test.ts
+++ b/std/fs/expand_glob_test.ts
@@ -6,15 +6,15 @@ import {
assertStringContains,
} from "../testing/asserts.ts";
import {
+ fromFileUrl,
join,
joinGlobs,
normalize,
relative,
- fromFileUrl,
} from "../path/mod.ts";
import {
- ExpandGlobOptions,
expandGlob,
+ ExpandGlobOptions,
expandGlobSync,
} from "./expand_glob.ts";
diff --git a/std/fs/walk_test.ts b/std/fs/walk_test.ts
index 1352ce448..c772f4912 100644
--- a/std/fs/walk_test.ts
+++ b/std/fs/walk_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { walk, walkSync, WalkOptions, WalkEntry } from "./walk.ts";
+import { walk, WalkEntry, WalkOptions, walkSync } from "./walk.ts";
import { assert, assertEquals, assertThrowsAsync } from "../testing/asserts.ts";
export function testWalk(
diff --git a/std/hash/sha1_test.ts b/std/hash/sha1_test.ts
index 89c60fe52..2caaff49b 100644
--- a/std/hash/sha1_test.ts
+++ b/std/hash/sha1_test.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { assertEquals } from "../testing/asserts.ts";
-import { Sha1, Message } from "./sha1.ts";
-import { dirname, join, resolve, fromFileUrl } from "../path/mod.ts";
+import { Message, Sha1 } from "./sha1.ts";
+import { dirname, fromFileUrl, join, resolve } from "../path/mod.ts";
const moduleDir = dirname(fromFileUrl(import.meta.url));
const testdataDir = resolve(moduleDir, "testdata");
diff --git a/std/hash/sha256_test.ts b/std/hash/sha256_test.ts
index fd9c227f4..1d03ea987 100644
--- a/std/hash/sha256_test.ts
+++ b/std/hash/sha256_test.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { Sha256, HmacSha256, Message } from "./sha256.ts";
+import { HmacSha256, Message, Sha256 } from "./sha256.ts";
import { assertEquals } from "../testing/asserts.ts";
-import { dirname, join, resolve, fromFileUrl } from "../path/mod.ts";
+import { dirname, fromFileUrl, join, resolve } from "../path/mod.ts";
const moduleDir = dirname(fromFileUrl(import.meta.url));
const testdataDir = resolve(moduleDir, "testdata");
diff --git a/std/hash/sha512_test.ts b/std/hash/sha512_test.ts
index ee49a229d..b9f72b150 100644
--- a/std/hash/sha512_test.ts
+++ b/std/hash/sha512_test.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { Sha512, HmacSha512, Message } from "./sha512.ts";
+import { HmacSha512, Message, Sha512 } from "./sha512.ts";
import { assertEquals } from "../testing/asserts.ts";
-import { dirname, join, resolve, fromFileUrl } from "../path/mod.ts";
+import { dirname, fromFileUrl, join, resolve } from "../path/mod.ts";
const moduleDir = dirname(fromFileUrl(import.meta.url));
const testdataDir = resolve(moduleDir, "testdata");
diff --git a/std/http/_io.ts b/std/http/_io.ts
index fefa6f657..1375edbb5 100644
--- a/std/http/_io.ts
+++ b/std/http/_io.ts
@@ -3,7 +3,7 @@ import { BufReader, BufWriter } from "../io/bufio.ts";
import { TextProtoReader } from "../textproto/mod.ts";
import { assert } from "../_util/assert.ts";
import { encoder } from "../encoding/utf8.ts";
-import { ServerRequest, Response } from "./server.ts";
+import { Response, ServerRequest } from "./server.ts";
import { STATUS_TEXT } from "./http_status.ts";
export function emptyReader(): Deno.Reader {
diff --git a/std/http/_io_test.ts b/std/http/_io_test.ts
index 7c7b3d8b4..14675a799 100644
--- a/std/http/_io_test.ts
+++ b/std/http/_io_test.ts
@@ -1,22 +1,22 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- assertThrowsAsync,
- assertEquals,
assert,
+ assertEquals,
assertNotEquals,
+ assertThrowsAsync,
} from "../testing/asserts.ts";
import {
bodyReader,
chunkedBodyReader,
- writeTrailers,
- readTrailers,
parseHTTPVersion,
readRequest,
+ readTrailers,
writeResponse,
+ writeTrailers,
} from "./_io.ts";
-import { encode, decode } from "../encoding/utf8.ts";
+import { decode, encode } from "../encoding/utf8.ts";
import { BufReader, ReadLineResult } from "../io/bufio.ts";
-import { ServerRequest, Response } from "./server.ts";
+import { Response, ServerRequest } from "./server.ts";
import { StringReader } from "../io/readers.ts";
import { mockConn } from "./_mock_conn.ts";
diff --git a/std/http/cookie_test.ts b/std/http/cookie_test.ts
index f34f5acae..0f7c68635 100644
--- a/std/http/cookie_test.ts
+++ b/std/http/cookie_test.ts
@@ -1,6 +1,6 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { ServerRequest, Response } from "./server.ts";
-import { getCookies, deleteCookie, setCookie } from "./cookie.ts";
+import { Response, ServerRequest } from "./server.ts";
+import { deleteCookie, getCookies, setCookie } from "./cookie.ts";
import { assert, assertEquals } from "../testing/asserts.ts";
Deno.test({
diff --git a/std/http/file_server.ts b/std/http/file_server.ts
index ff9a073e7..d8751eb84 100644
--- a/std/http/file_server.ts
+++ b/std/http/file_server.ts
@@ -6,13 +6,13 @@
// TODO Add tests like these:
// https://github.com/indexzero/http-server/blob/master/test/http-server-test.js
-import { posix, extname } from "../path/mod.ts";
+import { extname, posix } from "../path/mod.ts";
import {
+ HTTPSOptions,
listenAndServe,
listenAndServeTLS,
- ServerRequest,
Response,
- HTTPSOptions,
+ ServerRequest,
} from "./server.ts";
import { parse } from "../flags/mod.ts";
import { assert } from "../_util/assert.ts";
diff --git a/std/http/file_server_test.ts b/std/http/file_server_test.ts
index 93e6e5590..d8df631b8 100644
--- a/std/http/file_server_test.ts
+++ b/std/http/file_server_test.ts
@@ -3,8 +3,8 @@ import { assert, assertEquals } from "../testing/asserts.ts";
import { BufReader } from "../io/bufio.ts";
import { TextProtoReader } from "../textproto/mod.ts";
import { ServerRequest } from "./server.ts";
-import { serveFile, FileServerArgs } from "./file_server.ts";
-import { resolve, dirname, join, fromFileUrl } from "../path/mod.ts";
+import { FileServerArgs, serveFile } from "./file_server.ts";
+import { dirname, fromFileUrl, join, resolve } from "../path/mod.ts";
let fileServer: Deno.Process<Deno.RunOptions & { stdout: "piped" }>;
type FileServerCfg = Omit<FileServerArgs, "_"> & { target?: string };
diff --git a/std/http/server.ts b/std/http/server.ts
index 93f116fff..7bbdb7829 100644
--- a/std/http/server.ts
+++ b/std/http/server.ts
@@ -2,13 +2,13 @@
import { encode } from "../encoding/utf8.ts";
import { BufReader, BufWriter } from "../io/bufio.ts";
import { assert } from "../_util/assert.ts";
-import { deferred, Deferred, MuxAsyncIterator } from "../async/mod.ts";
+import { Deferred, deferred, MuxAsyncIterator } from "../async/mod.ts";
import {
bodyReader,
chunkedBodyReader,
emptyReader,
- writeResponse,
readRequest,
+ writeResponse,
} from "./_io.ts";
export class ServerRequest {
diff --git a/std/http/server_test.ts b/std/http/server_test.ts
index 564ec4e07..76b0bcff9 100644
--- a/std/http/server_test.ts
+++ b/std/http/server_test.ts
@@ -14,18 +14,18 @@ import {
assertThrowsAsync,
} from "../testing/asserts.ts";
import {
+ _parseAddrFromStr,
Response,
- ServerRequest,
- Server,
serve,
+ Server,
+ ServerRequest,
serveTLS,
- _parseAddrFromStr,
} from "./server.ts";
import { BufReader, BufWriter } from "../io/bufio.ts";
import { delay } from "../async/delay.ts";
-import { encode, decode } from "../encoding/utf8.ts";
+import { decode, encode } from "../encoding/utf8.ts";
import { mockConn } from "./_mock_conn.ts";
-import { resolve, dirname, join, fromFileUrl } from "../path/mod.ts";
+import { dirname, fromFileUrl, join, resolve } from "../path/mod.ts";
const moduleDir = dirname(fromFileUrl(import.meta.url));
const testdataDir = resolve(moduleDir, "testdata");
diff --git a/std/io/README.md b/std/io/README.md
index 09918fcc4..ca0f5f441 100644
--- a/std/io/README.md
+++ b/std/io/README.md
@@ -101,9 +101,9 @@ Create a `Writer` object for `string`.
```ts
import {
- StringWriter,
- StringReader,
copyN,
+ StringReader,
+ StringWriter,
} from "https://deno.land/std/io/mod.ts";
const w = new StringWriter("base");
diff --git a/std/io/bufio_test.ts b/std/io/bufio_test.ts
index bddefb38c..d647082ad 100644
--- a/std/io/bufio_test.ts
+++ b/std/io/bufio_test.ts
@@ -5,14 +5,14 @@
// license that can be found in the LICENSE file.
import { assert, assertEquals, fail } from "../testing/asserts.ts";
import {
+ BufferFullError,
BufReader,
BufWriter,
BufWriterSync,
- BufferFullError,
PartialReadError,
ReadLineResult,
- readStringDelim,
readLines,
+ readStringDelim,
} from "./bufio.ts";
import * as iotest from "./_iotest.ts";
import { StringReader } from "./readers.ts";
diff --git a/std/io/streams_test.ts b/std/io/streams_test.ts
index 4579e3668..81881ceb9 100644
--- a/std/io/streams_test.ts
+++ b/std/io/streams_test.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { assertEquals, assert } from "../testing/asserts.ts";
-import { fromStreamWriter, fromStreamReader } from "./streams.ts";
+import { assert, assertEquals } from "../testing/asserts.ts";
+import { fromStreamReader, fromStreamWriter } from "./streams.ts";
function repeat(c: string, bytes: number): Uint8Array {
assertEquals(c.length, 1);
diff --git a/std/log/handlers.ts b/std/log/handlers.ts
index 21c25a816..c538de380 100644
--- a/std/log/handlers.ts
+++ b/std/log/handlers.ts
@@ -1,8 +1,8 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { getLevelByName, LevelName, LogLevels } from "./levels.ts";
import type { LogRecord } from "./logger.ts";
-import { red, yellow, blue, bold } from "../fmt/colors.ts";
-import { existsSync, exists } from "../fs/exists.ts";
+import { blue, bold, red, yellow } from "../fmt/colors.ts";
+import { exists, existsSync } from "../fs/exists.ts";
import { BufWriterSync } from "../io/bufio.ts";
const DEFAULT_FORMATTER = "{levelName} {msg}";
diff --git a/std/log/handlers_test.ts b/std/log/handlers_test.ts
index 8921dd542..52c1edb64 100644
--- a/std/log/handlers_test.ts
+++ b/std/log/handlers_test.ts
@@ -2,15 +2,15 @@
import {
assert,
assertEquals,
- assertThrowsAsync,
assertNotEquals,
+ assertThrowsAsync,
} from "../testing/asserts.ts";
import {
- LogLevels,
- LogLevelNames,
- getLevelName,
getLevelByName,
+ getLevelName,
LevelName,
+ LogLevelNames,
+ LogLevels,
} from "./levels.ts";
import { BaseHandler, FileHandler, RotatingFileHandler } from "./handlers.ts";
import { LogRecord } from "./logger.ts";
diff --git a/std/log/logger.ts b/std/log/logger.ts
index c00ab78ec..e3ffc224a 100644
--- a/std/log/logger.ts
+++ b/std/log/logger.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { LogLevels, getLevelByName, getLevelName } from "./levels.ts";
+import { getLevelByName, getLevelName, LogLevels } from "./levels.ts";
import type { LevelName } from "./levels.ts";
import type { BaseHandler } from "./handlers.ts";
diff --git a/std/log/logger_test.ts b/std/log/logger_test.ts
index 08080356b..4ab50809f 100644
--- a/std/log/logger_test.ts
+++ b/std/log/logger_test.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { assertEquals, assert } from "../testing/asserts.ts";
-import { LogRecord, Logger } from "./logger.ts";
-import { LogLevels, LevelName } from "./levels.ts";
+import { assert, assertEquals } from "../testing/asserts.ts";
+import { Logger, LogRecord } from "./logger.ts";
+import { LevelName, LogLevels } from "./levels.ts";
import { BaseHandler } from "./handlers.ts";
class TestHandler extends BaseHandler {
diff --git a/std/log/mod.ts b/std/log/mod.ts
index 512de534b..167d86a5c 100644
--- a/std/log/mod.ts
+++ b/std/log/mod.ts
@@ -4,9 +4,9 @@ import type { GenericFunction } from "./logger.ts";
import {
BaseHandler,
ConsoleHandler,
- WriterHandler,
FileHandler,
RotatingFileHandler,
+ WriterHandler,
} from "./handlers.ts";
import { assert } from "../_util/assert.ts";
import type { LevelName } from "./levels.ts";
diff --git a/std/log/mod_test.ts b/std/log/mod_test.ts
index 30c6b0914..f2467ef68 100644
--- a/std/log/mod_test.ts
+++ b/std/log/mod_test.ts
@@ -1,16 +1,16 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { assert, assertEquals } from "../testing/asserts.ts";
import {
- getLogger,
+ critical,
debug,
- info,
- warning,
error,
- critical,
- setup,
+ getLogger,
+ info,
+ LevelName,
Logger,
LogLevels,
- LevelName,
+ setup,
+ warning,
} from "./mod.ts";
import { BaseHandler } from "./handlers.ts";
diff --git a/std/log/test.ts b/std/log/test.ts
index 0c0ab0703..23eac7ff4 100644
--- a/std/log/test.ts
+++ b/std/log/test.ts
@@ -2,10 +2,10 @@
import { assertEquals, assertThrows } from "../testing/asserts.ts";
import * as log from "./mod.ts";
import {
- LogLevelNames,
- LevelName,
getLevelByName,
getLevelName,
+ LevelName,
+ LogLevelNames,
} from "./levels.ts";
class TestHandler extends log.handlers.BaseHandler {
diff --git a/std/mime/multipart_test.ts b/std/mime/multipart_test.ts
index df533194c..3180009c8 100644
--- a/std/mime/multipart_test.ts
+++ b/std/mime/multipart_test.ts
@@ -7,10 +7,10 @@ import {
} from "../testing/asserts.ts";
import * as path from "../path/mod.ts";
import {
- MultipartReader,
- MultipartWriter,
isFormFile,
matchAfterPrefix,
+ MultipartReader,
+ MultipartWriter,
scanUntilBoundary,
} from "./multipart.ts";
import { StringWriter } from "../io/writers.ts";
diff --git a/std/node/_fs/_fs_appendFile.ts b/std/node/_fs/_fs_appendFile.ts
index bc30de609..cb51def67 100644
--- a/std/node/_fs/_fs_appendFile.ts
+++ b/std/node/_fs/_fs_appendFile.ts
@@ -1,10 +1,10 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
- Encodings,
- WriteFileOptions,
- isFileOptions,
CallbackWithError,
+ Encodings,
getOpenOptions,
+ isFileOptions,
+ WriteFileOptions,
} from "./_fs_common.ts";
import { notImplemented } from "../_utils.ts";
import { fromFileUrl } from "../path.ts";
diff --git a/std/node/_fs/_fs_chmod_test.ts b/std/node/_fs/_fs_chmod_test.ts
index de4981a8c..a9ff7ed7d 100644
--- a/std/node/_fs/_fs_chmod_test.ts
+++ b/std/node/_fs/_fs_chmod_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { fail, assert } from "../../testing/asserts.ts";
+import { assert, fail } from "../../testing/asserts.ts";
import { chmod, chmodSync } from "./_fs_chmod.ts";
Deno.test({
diff --git a/std/node/_fs/_fs_chown_test.ts b/std/node/_fs/_fs_chown_test.ts
index de7dd992f..b053a7584 100644
--- a/std/node/_fs/_fs_chown_test.ts
+++ b/std/node/_fs/_fs_chown_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { fail, assertEquals } from "../../testing/asserts.ts";
+import { assertEquals, fail } from "../../testing/asserts.ts";
import { chown, chownSync } from "./_fs_chown.ts";
// chown is difficult to test. Best we can do is set the existing user id/group
diff --git a/std/node/_fs/_fs_close_test.ts b/std/node/_fs/_fs_close_test.ts
index feaf92ab8..173213816 100644
--- a/std/node/_fs/_fs_close_test.ts
+++ b/std/node/_fs/_fs_close_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { fail, assert, assertThrows } from "../../testing/asserts.ts";
+import { assert, assertThrows, fail } from "../../testing/asserts.ts";
import { close, closeSync } from "./_fs_close.ts";
Deno.test({
diff --git a/std/node/_fs/_fs_link_test.ts b/std/node/_fs/_fs_link_test.ts
index ae97f6676..7d1cbfd4f 100644
--- a/std/node/_fs/_fs_link_test.ts
+++ b/std/node/_fs/_fs_link_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { fail, assertEquals } from "../../testing/asserts.ts";
+import { assertEquals, fail } from "../../testing/asserts.ts";
import { link, linkSync } from "./_fs_link.ts";
import { assert } from "../../testing/asserts.ts";
diff --git a/std/node/_fs/_fs_readFile.ts b/std/node/_fs/_fs_readFile.ts
index 2aef28290..e4a7d2031 100644
--- a/std/node/_fs/_fs_readFile.ts
+++ b/std/node/_fs/_fs_readFile.ts
@@ -1,12 +1,12 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
+ BinaryEncodings,
+ BinaryOptionsArgument,
Encodings,
- getEncoding,
FileOptionsArgument,
- TextOptionsArgument,
- BinaryOptionsArgument,
+ getEncoding,
TextEncodings,
- BinaryEncodings,
+ TextOptionsArgument,
} from "./_fs_common.ts";
import { Buffer } from "../buffer.ts";
import { fromFileUrl } from "../path.ts";
diff --git a/std/node/_fs/_fs_readFile_test.ts b/std/node/_fs/_fs_readFile_test.ts
index 2ea7831d4..bc2635e82 100644
--- a/std/node/_fs/_fs_readFile_test.ts
+++ b/std/node/_fs/_fs_readFile_test.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { readFile, readFileSync } from "./_fs_readFile.ts";
import * as path from "../../path/mod.ts";
-import { assertEquals, assert } from "../../testing/asserts.ts";
+import { assert, assertEquals } from "../../testing/asserts.ts";
const moduleDir = path.dirname(path.fromFileUrl(import.meta.url));
const testData = path.resolve(moduleDir, "testdata", "hello.txt");
diff --git a/std/node/_fs/_fs_readlink_test.ts b/std/node/_fs/_fs_readlink_test.ts
index 0b220caa4..61bc3b004 100644
--- a/std/node/_fs/_fs_readlink_test.ts
+++ b/std/node/_fs/_fs_readlink_test.ts
@@ -1,6 +1,6 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { readlink, readlinkSync } from "./_fs_readlink.ts";
-import { assertEquals, assert } from "../../testing/asserts.ts";
+import { assert, assertEquals } from "../../testing/asserts.ts";
import * as path from "../path.ts";
const testDir = Deno.makeTempDirSync();
diff --git a/std/node/_fs/_fs_writeFile.ts b/std/node/_fs/_fs_writeFile.ts
index a8ae1f586..19181ee21 100644
--- a/std/node/_fs/_fs_writeFile.ts
+++ b/std/node/_fs/_fs_writeFile.ts
@@ -4,13 +4,13 @@ import { fromFileUrl } from "../path.ts";
import { Buffer } from "../buffer.ts";
import {
- Encodings,
- WriteFileOptions,
CallbackWithError,
- isFileOptions,
- getEncoding,
checkEncoding,
+ Encodings,
+ getEncoding,
getOpenOptions,
+ isFileOptions,
+ WriteFileOptions,
} from "./_fs_common.ts";
export function writeFile(
diff --git a/std/node/_fs/promises/_fs_readFile.ts b/std/node/_fs/promises/_fs_readFile.ts
index 446c48625..fed5367ed 100644
--- a/std/node/_fs/promises/_fs_readFile.ts
+++ b/std/node/_fs/promises/_fs_readFile.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import type {
- FileOptionsArgument,
BinaryOptionsArgument,
+ FileOptionsArgument,
TextOptionsArgument,
} from "../_fs_common.ts";
import { readFile as readFileCallback } from "../_fs_readFile.ts";
diff --git a/std/node/_fs/promises/_fs_readFile_test.ts b/std/node/_fs/promises/_fs_readFile_test.ts
index 53ef373e5..2068797b9 100644
--- a/std/node/_fs/promises/_fs_readFile_test.ts
+++ b/std/node/_fs/promises/_fs_readFile_test.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { readFile } from "./_fs_readFile.ts";
import * as path from "../../../path/mod.ts";
-import { assertEquals, assert } from "../../../testing/asserts.ts";
+import { assert, assertEquals } from "../../../testing/asserts.ts";
const moduleDir = path.dirname(path.fromFileUrl(import.meta.url));
const testData = path.resolve(moduleDir, "..", "testdata", "hello.txt");
diff --git a/std/node/_util/_util_types_test.ts b/std/node/_util/_util_types_test.ts
index fff0dad0c..0b9872bbb 100644
--- a/std/node/_util/_util_types_test.ts
+++ b/std/node/_util/_util_types_test.ts
@@ -22,42 +22,42 @@
// USE OR OTHER DEALINGS IN THE SOFTWARE.
import { assertStrictEquals } from "../../testing/asserts.ts";
import {
- isDate,
- isMap,
- isSet,
isAnyArrayBuffer,
- isArrayBufferView,
isArgumentsObject,
isArrayBuffer,
- isStringObject,
+ isArrayBufferView,
isAsyncFunction,
isBigInt64Array,
+ isBigIntObject,
isBigUint64Array,
isBooleanObject,
isBoxedPrimitive,
isDataView,
+ isDate,
isFloat32Array,
isFloat64Array,
isGeneratorFunction,
isGeneratorObject,
- isInt8Array,
isInt16Array,
isInt32Array,
+ isInt8Array,
+ isMap,
isMapIterator,
isModuleNamespaceObject,
isNativeError,
- isSymbolObject,
- isTypedArray,
- isUint8Array,
- isUint8ClampedArray,
- isUint16Array,
- isUint32Array,
isNumberObject,
- isBigIntObject,
isPromise,
isRegExp,
+ isSet,
isSetIterator,
isSharedArrayBuffer,
+ isStringObject,
+ isSymbolObject,
+ isTypedArray,
+ isUint16Array,
+ isUint32Array,
+ isUint8Array,
+ isUint8ClampedArray,
isWeakMap,
isWeakSet,
} from "./_util_types.ts";
diff --git a/std/node/assert.ts b/std/node/assert.ts
index 78bc4b3b5..ad353912e 100644
--- a/std/node/assert.ts
+++ b/std/node/assert.ts
@@ -1,19 +1,19 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
assertEquals,
+ assertMatch,
assertNotEquals,
- assertStrictEquals,
assertNotStrictEquals,
- assertMatch,
+ assertStrictEquals,
assertThrows,
} from "../testing/asserts.ts";
export { AssertionError } from "./assertion_error.ts";
export {
+ assert,
assert as default,
assert as ok,
- assert,
fail,
} from "../testing/asserts.ts";
diff --git a/std/node/assert_test.ts b/std/node/assert_test.ts
index defcaa425..01a722ed3 100644
--- a/std/node/assert_test.ts
+++ b/std/node/assert_test.ts
@@ -2,10 +2,10 @@
import {
assert as denoAssert,
assertEquals,
+ assertMatch,
assertNotEquals,
- assertStrictEquals,
assertNotStrictEquals,
- assertMatch,
+ assertStrictEquals,
assertThrows,
fail as denoFail,
} from "../testing/asserts.ts";
@@ -13,16 +13,16 @@ import {
import AssertionError from "./assertion_error.ts";
import assert, {
- ok,
assert as assert_,
+ AssertionError as AssertionError_,
deepStrictEqual,
+ fail,
+ match,
notDeepStrictEqual,
- strictEqual,
notStrictEqual,
- match,
+ ok,
+ strictEqual,
throws,
- fail,
- AssertionError as AssertionError_,
} from "./assert.ts";
Deno.test("API should be exposed", () => {
diff --git a/std/node/assertion_error_test.ts b/std/node/assertion_error_test.ts
index 74187bc3a..2faa191f2 100644
--- a/std/node/assertion_error_test.ts
+++ b/std/node/assertion_error_test.ts
@@ -9,8 +9,8 @@ import {
import {
AssertionError,
copyError,
- inspectValue,
createErrDiff,
+ inspectValue,
} from "./assertion_error.ts";
Deno.test({
diff --git a/std/node/buffer.ts b/std/node/buffer.ts
index 24b77e323..2a9f0bb56 100644
--- a/std/node/buffer.ts
+++ b/std/node/buffer.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import * as hex from "../encoding/hex.ts";
import * as base64 from "../encoding/base64.ts";
-import { notImplemented, normalizeEncoding } from "./_utils.ts";
+import { normalizeEncoding, notImplemented } from "./_utils.ts";
const notImplementedEncodings = [
"ascii",
diff --git a/std/node/events_test.ts b/std/node/events_test.ts
index 557a3924d..b8324c74f 100644
--- a/std/node/events_test.ts
+++ b/std/node/events_test.ts
@@ -2,10 +2,10 @@
import {
assert,
assertEquals,
- fail,
assertThrows,
+ fail,
} from "../testing/asserts.ts";
-import EventEmitter, { WrappedFunction, once, on } from "./events.ts";
+import EventEmitter, { on, once, WrappedFunction } from "./events.ts";
const shouldNeverBeEmitted = () => {
fail("Should never be called");
diff --git a/std/node/fs.ts b/std/node/fs.ts
index 31e2e5ded..adb3a7c63 100644
--- a/std/node/fs.ts
+++ b/std/node/fs.ts
@@ -29,13 +29,13 @@ export {
copyFileSync,
exists,
existsSync,
+ mkdir,
+ mkdirSync,
+ promises,
readFile,
readFileSync,
readlink,
readlinkSync,
- mkdir,
- mkdirSync,
writeFile,
writeFileSync,
- promises,
};
diff --git a/std/node/module.ts b/std/node/module.ts
index 534fe88e4..a9a1b38d8 100644
--- a/std/node/module.ts
+++ b/std/node/module.ts
@@ -33,7 +33,7 @@ import * as nodeUtil from "./util.ts";
import * as path from "../path/mod.ts";
import { assert } from "../_util/assert.ts";
-import { pathToFileURL, fileURLToPath } from "./url.ts";
+import { fileURLToPath, pathToFileURL } from "./url.ts";
const CHAR_FORWARD_SLASH = "/".charCodeAt(0);
const CHAR_BACKWARD_SLASH = "\\".charCodeAt(0);
diff --git a/std/node/module_test.ts b/std/node/module_test.ts
index 4752763c9..2b8c5c790 100644
--- a/std/node/module_test.ts
+++ b/std/node/module_test.ts
@@ -1,8 +1,8 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
/* eslint-disable @typescript-eslint/no-var-requires */
import {
- assertEquals,
assert,
+ assertEquals,
assertStringContains,
} from "../testing/asserts.ts";
diff --git a/std/node/os_test.ts b/std/node/os_test.ts
index 89a0a03aa..e4231aa3c 100644
--- a/std/node/os_test.ts
+++ b/std/node/os_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { assert, assertThrows, assertEquals } from "../testing/asserts.ts";
+import { assert, assertEquals, assertThrows } from "../testing/asserts.ts";
import * as os from "./os.ts";
Deno.test({
diff --git a/std/node/process_test.ts b/std/node/process_test.ts
index 684beb8d2..6e6145e67 100644
--- a/std/node/process_test.ts
+++ b/std/node/process_test.ts
@@ -1,10 +1,10 @@
// deno-lint-ignore-file no-undef
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
-import { assert, assertThrows, assertEquals } from "../testing/asserts.ts";
+import { assert, assertEquals, assertThrows } from "../testing/asserts.ts";
import * as path from "../path/mod.ts";
import * as all from "./process.ts";
-import { env, argv } from "./process.ts";
+import { argv, env } from "./process.ts";
// NOTE: Deno.execPath() (and thus process.argv) currently requires --allow-env
// (Also Deno.env.toObject() (and process.env) requires --allow-env but it's more obvious)
diff --git a/std/node/querystring_test.ts b/std/node/querystring_test.ts
index 7f1efd4fd..63447b94a 100644
--- a/std/node/querystring_test.ts
+++ b/std/node/querystring_test.ts
@@ -1,6 +1,6 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { assertEquals } from "../testing/asserts.ts";
-import { stringify, parse } from "./querystring.ts";
+import { parse, stringify } from "./querystring.ts";
Deno.test({
name: "stringify",
diff --git a/std/node/url.ts b/std/node/url.ts
index 577c5eaf2..70e1645b6 100644
--- a/std/node/url.ts
+++ b/std/node/url.ts
@@ -20,10 +20,10 @@
// USE OR OTHER DEALINGS IN THE SOFTWARE.
import {
+ CHAR_BACKWARD_SLASH,
+ CHAR_FORWARD_SLASH,
CHAR_LOWERCASE_A,
CHAR_LOWERCASE_Z,
- CHAR_FORWARD_SLASH,
- CHAR_BACKWARD_SLASH,
} from "../path/_constants.ts";
import * as path from "./path.ts";
diff --git a/std/path/_util.ts b/std/path/_util.ts
index ead425a0b..37ef847cf 100644
--- a/std/path/_util.ts
+++ b/std/path/_util.ts
@@ -4,13 +4,13 @@
import type { FormatInputPathObject } from "./_interface.ts";
import {
- CHAR_UPPERCASE_A,
- CHAR_LOWERCASE_A,
- CHAR_UPPERCASE_Z,
- CHAR_LOWERCASE_Z,
+ CHAR_BACKWARD_SLASH,
CHAR_DOT,
CHAR_FORWARD_SLASH,
- CHAR_BACKWARD_SLASH,
+ CHAR_LOWERCASE_A,
+ CHAR_LOWERCASE_Z,
+ CHAR_UPPERCASE_A,
+ CHAR_UPPERCASE_Z,
} from "./_constants.ts";
export function assertPath(path: string): void {
diff --git a/std/path/glob_test.ts b/std/path/glob_test.ts
index 015988cfe..96cab43dc 100644
--- a/std/path/glob_test.ts
+++ b/std/path/glob_test.ts
@@ -1,8 +1,8 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { assert, assertEquals } from "../testing/asserts.ts";
import {
- GlobToRegExpOptions,
globToRegExp,
+ GlobToRegExpOptions,
isGlob,
joinGlobs,
normalizeGlob,
diff --git a/std/path/parse_format_test.ts b/std/path/parse_format_test.ts
index 1b34ddc29..785588359 100644
--- a/std/path/parse_format_test.ts
+++ b/std/path/parse_format_test.ts
@@ -3,7 +3,7 @@
import type { FormatInputPathObject, ParsedPath } from "./mod.ts";
import { assertEquals } from "../testing/asserts.ts";
-import { win32, posix } from "./mod.ts";
+import { posix, win32 } from "./mod.ts";
type FormatTestCase = [FormatInputPathObject, string];
type ParseTestCase = [string, ParsedPath];
diff --git a/std/path/posix.ts b/std/path/posix.ts
index 33b94a916..68ffb06c9 100644
--- a/std/path/posix.ts
+++ b/std/path/posix.ts
@@ -6,10 +6,10 @@ import type { FormatInputPathObject, ParsedPath } from "./_interface.ts";
import { CHAR_DOT, CHAR_FORWARD_SLASH } from "./_constants.ts";
import {
+ _format,
assertPath,
- normalizeString,
isPosixPathSeparator,
- _format,
+ normalizeString,
} from "./_util.ts";
export const sep = "/";
diff --git a/std/path/win32.ts b/std/path/win32.ts
index 19b29a6b9..246c18a97 100644
--- a/std/path/win32.ts
+++ b/std/path/win32.ts
@@ -4,18 +4,18 @@
import type { FormatInputPathObject, ParsedPath } from "./_interface.ts";
import {
- CHAR_DOT,
CHAR_BACKWARD_SLASH,
CHAR_COLON,
+ CHAR_DOT,
CHAR_QUESTION_MARK,
} from "./_constants.ts";
import {
+ _format,
assertPath,
isPathSeparator,
isWindowsDeviceRoot,
normalizeString,
- _format,
} from "./_util.ts";
import { assert } from "../_util/assert.ts";
diff --git a/std/signal/test.ts b/std/signal/test.ts
index 8f495dfb3..13f2b2676 100644
--- a/std/signal/test.ts
+++ b/std/signal/test.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { assertEquals, assertThrows } from "../testing/asserts.ts";
import { delay } from "../async/delay.ts";
-import { signal, onSignal } from "./mod.ts";
+import { onSignal, signal } from "./mod.ts";
Deno.test({
name: "signal() throws when called with empty signals",
diff --git a/std/testing/README.md b/std/testing/README.md
index 00169384c..82351d94a 100644
--- a/std/testing/README.md
+++ b/std/testing/README.md
@@ -156,7 +156,7 @@ After that simply calling `runBenchmarks()` will benchmark all registered
benchmarks and log the results in the commandline.
```ts
-import { runBenchmarks, bench } from "https://deno.land/std/testing/bench.ts";
+import { bench, runBenchmarks } from "https://deno.land/std/testing/bench.ts";
bench(function forIncrementX1e9(b): void {
b.start();
diff --git a/std/testing/asserts.ts b/std/testing/asserts.ts
index 9796c9d31..05bb995ab 100644
--- a/std/testing/asserts.ts
+++ b/std/testing/asserts.ts
@@ -2,8 +2,8 @@
/** This module is browser compatible. Do not rely on good formatting of values
* for AssertionError messages in browsers. */
-import { red, green, white, gray, bold, stripColor } from "../fmt/colors.ts";
-import diff, { DiffType, DiffResult } from "./diff.ts";
+import { bold, gray, green, red, stripColor, white } from "../fmt/colors.ts";
+import diff, { DiffResult, DiffType } from "./diff.ts";
const CAN_NOT_DISPLAY = "[Cannot display]";
diff --git a/std/testing/asserts_test.ts b/std/testing/asserts_test.ts
index 4840bcf53..7b57fbfa0 100644
--- a/std/testing/asserts_test.ts
+++ b/std/testing/asserts_test.ts
@@ -2,23 +2,23 @@
import {
_format,
assert,
- assertNotEquals,
- assertStringContains,
assertArrayContains,
+ assertEquals,
+ AssertionError,
assertMatch,
+ assertNotEquals,
assertNotMatch,
- assertEquals,
- assertStrictEquals,
assertNotStrictEquals,
+ assertStrictEquals,
+ assertStringContains,
assertThrows,
assertThrowsAsync,
- AssertionError,
equal,
fail,
unimplemented,
unreachable,
} from "./asserts.ts";
-import { red, green, gray, bold, yellow, stripColor } from "../fmt/colors.ts";
+import { bold, gray, green, red, stripColor, yellow } from "../fmt/colors.ts";
Deno.test("testingEqual", function (): void {
assert(equal("world", "world"));
diff --git a/std/testing/bench_example.ts b/std/testing/bench_example.ts
index 41b1ca65c..496033fff 100644
--- a/std/testing/bench_example.ts
+++ b/std/testing/bench_example.ts
@@ -1,6 +1,6 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
// https://deno.land/std/testing/bench.ts
-import { BenchmarkTimer, bench, runBenchmarks } from "./bench.ts";
+import { bench, BenchmarkTimer, runBenchmarks } from "./bench.ts";
// Basic
bench(function forIncrementX1e9(b: BenchmarkTimer): void {
diff --git a/std/testing/bench_test.ts b/std/testing/bench_test.ts
index 97517358a..18b78c5a2 100644
--- a/std/testing/bench_test.ts
+++ b/std/testing/bench_test.ts
@@ -1,15 +1,15 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import {
bench,
- runBenchmarks,
BenchmarkRunError,
- clearBenchmarks,
BenchmarkRunProgress,
+ clearBenchmarks,
ProgressState,
+ runBenchmarks,
} from "./bench.ts";
import {
- assertEquals,
assert,
+ assertEquals,
assertThrows,
assertThrowsAsync,
} from "./asserts.ts";
diff --git a/std/uuid/test.ts b/std/uuid/test.ts
index 643ad6b55..2dff12566 100644
--- a/std/uuid/test.ts
+++ b/std/uuid/test.ts
@@ -1,6 +1,6 @@
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
import { assert } from "../testing/asserts.ts";
-import { NIL_UUID, isNil } from "./mod.ts";
+import { isNil, NIL_UUID } from "./mod.ts";
Deno.test({
name: "[UUID] isNil",
diff --git a/std/ws/test.ts b/std/ws/test.ts
index 787cb76e2..e8fa4f8b1 100644
--- a/std/ws/test.ts
+++ b/std/ws/test.ts
@@ -7,14 +7,14 @@ import {
acceptable,
createSecAccept,
createSecKey,
+ createWebSocket,
handshake,
OpCode,
readFrame,
unmask,
writeFrame,
- createWebSocket,
} from "./mod.ts";
-import { encode, decode } from "../encoding/utf8.ts";
+import { decode, encode } from "../encoding/utf8.ts";
import { delay } from "../async/delay.ts";
Deno.test("[ws] read unmasked text frame", async () => {