From fd900cfe215e919392941b39b57a16b4a9976eec Mon Sep 17 00:00:00 2001 From: Casper Beyer Date: Thu, 23 Jul 2020 10:18:18 +0800 Subject: BREAKING(std/fs): remove readFileStr and readFileStrSync (#6848) This removes the readFileStr and readFileStrSync functions which are effectively duplicates of Deno.readTextFile and Deno.readTextFileSync. --- std/encoding/toml_test.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'std/encoding/toml_test.ts') diff --git a/std/encoding/toml_test.ts b/std/encoding/toml_test.ts index 5d651c822..45d0a66e6 100644 --- a/std/encoding/toml_test.ts +++ b/std/encoding/toml_test.ts @@ -1,7 +1,6 @@ // Copyright 2018-2020 the Deno authors. All rights reserved. MIT license. import { assertEquals } from "../testing/asserts.ts"; import { existsSync } from "../fs/exists.ts"; -import { readFileStrSync } from "../fs/read_file_str.ts"; import * as path from "../path/mod.ts"; import { parse, stringify } from "./toml.ts"; @@ -11,8 +10,7 @@ function parseFile(filePath: string): object { if (!existsSync(filePath)) { throw new Error(`File not found: ${filePath}`); } - const strFile = readFileStrSync(filePath); - return parse(strFile); + return parse(Deno.readTextFileSync(filePath)); } Deno.test({ -- cgit v1.2.3