From 51e0bfda3c5df4fa1f1b36301193038ed6aaf7bf Mon Sep 17 00:00:00 2001 From: Luca Casonato Date: Mon, 12 Jul 2021 19:44:42 +0200 Subject: chore(runtime): deprecate `Deno.copy` (#11369) --- cli/bench/deno_tcp_proxy.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'cli/bench/deno_tcp_proxy.ts') diff --git a/cli/bench/deno_tcp_proxy.ts b/cli/bench/deno_tcp_proxy.ts index bab8eac19..df74de8c4 100644 --- a/cli/bench/deno_tcp_proxy.ts +++ b/cli/bench/deno_tcp_proxy.ts @@ -1,5 +1,7 @@ // Copyright 2018-2021 the Deno authors. All rights reserved. MIT license. // Used for benchmarking Deno's tcp proxy performance. +import { copy } from "../../test_util/std/io/util.ts"; + const addr = Deno.args[0] || "127.0.0.1:4500"; const originAddr = Deno.args[1] || "127.0.0.1:4501"; @@ -14,7 +16,7 @@ async function handle(conn: Deno.Conn): Promise { port: Number(originPort), }); try { - await Promise.all([Deno.copy(conn, origin), Deno.copy(origin, conn)]); + await Promise.all([copy(conn, origin), copy(origin, conn)]); } catch (e) { if ( !(e instanceof Deno.errors.BrokenPipe) && -- cgit v1.2.3