Skip to content

Commit

Permalink
Update deno std to 0.133.0
Browse files Browse the repository at this point in the history
  • Loading branch information
vslinko committed Apr 6, 2022
1 parent b7e59f0 commit e01edb6
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 17 deletions.
10 changes: 5 additions & 5 deletions deps.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
export {
concat,
indexOf,
indexOfNeedle,
repeat,
} from "https://deno.land/std@0.117.0/bytes/mod.ts";
export { getLogger } from "https://deno.land/std@0.117.0/log/mod.ts";
export { Logger } from "https://deno.land/std@0.117.0/log/logger.ts";
export { iter } from "https://deno.land/std@0.117.0/io/util.ts";
} from "https://deno.land/std@0.133.0/bytes/mod.ts";
export { getLogger } from "https://deno.land/std@0.133.0/log/mod.ts";
export { Logger } from "https://deno.land/std@0.133.0/log/logger.ts";
export { iter } from "https://deno.land/std@0.133.0/io/util.ts";
8 changes: 4 additions & 4 deletions dev_deps.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
export {
assertEquals,
assertThrowsAsync,
} from "https://deno.land/std@0.117.0/testing/asserts.ts";
export * as log from "https://deno.land/std@0.117.0/log/mod.ts";
export { Buffer } from "https://deno.land/std@0.117.0/io/buffer.ts";
assertRejects,
} from "https://deno.land/std@0.133.0/testing/asserts.ts";
export * as log from "https://deno.land/std@0.133.0/log/mod.ts";
export { Buffer } from "https://deno.land/std@0.133.0/io/buffer.ts";
8 changes: 4 additions & 4 deletions reader_test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals, assertThrowsAsync } from "./dev_deps.ts";
import { assertEquals, assertRejects } from "./dev_deps.ts";
import {
readCSV,
readCSVObjects,
Expand Down Expand Up @@ -135,7 +135,7 @@ Deno.test({
async fn() {
const reader = new MyReader(`1,"2`);

assertThrowsAsync(
assertRejects(
async () => {
await asyncArrayFrom2(readCSV(reader));
},
Expand All @@ -150,7 +150,7 @@ Deno.test({
async fn() {
const reader = new MyReader(`1,"2"3`);

assertThrowsAsync(
assertRejects(
async () => {
await asyncArrayFrom2(readCSV(reader));
},
Expand All @@ -172,7 +172,7 @@ Deno.test({
1"2
1,2`);

assertThrowsAsync(
assertRejects(
async () => {
await asyncArrayFrom2(readCSV(reader));
},
Expand Down
8 changes: 4 additions & 4 deletions writer.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { concat, indexOf } from "./deps.ts";
import { concat, indexOfNeedle } from "./deps.ts";
import {
dummyAsyncIterable,
getUint8Array,
Expand Down Expand Up @@ -69,9 +69,9 @@ export class CSVWriter {

const arr = getUint8Array(str);
const wrap = options?.forceQuotes ||
indexOf(arr, this.quote) >= 0 ||
indexOf(arr, this.columnSeparator) >= 0 ||
indexOf(arr, this.lineSeparator) >= 0;
indexOfNeedle(arr, this.quote) >= 0 ||
indexOfNeedle(arr, this.columnSeparator) >= 0 ||
indexOfNeedle(arr, this.lineSeparator) >= 0;

return this._writeCellAsyncIterable(dummyAsyncIterable(arr), {
wrap,
Expand Down

0 comments on commit e01edb6

Please sign in to comment.