From 6e13957635a704850b847eb711723b264350ed5e Mon Sep 17 00:00:00 2001 From: Kyle June Date: Mon, 7 Feb 2022 19:16:17 -0600 Subject: [PATCH] Bump version and update dependencies --- README.md | 34 +++++++++++++++++----------------- deps.ts | 6 +++--- 2 files changed, 20 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index 6503969..19127e2 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # Mock -[![release](https://img.shields.io/badge/release-0.12.2-success)](https://github.com/udibo/mock/releases/tag/0.12.2) -[![deno doc](https://doc.deno.land/badge.svg)](https://doc.deno.land/https/deno.land/x/mock@0.12.2/mod.ts) +[![release](https://img.shields.io/badge/release-0.13.0-success)](https://github.com/udibo/mock/releases/tag/0.13.0) +[![deno doc](https://doc.deno.land/badge.svg)](https://doc.deno.land/https/deno.land/x/mock@0.13.0/mod.ts) [![CI](https://github.com/udibo/mock/workflows/CI/badge.svg)](https://github.com/udibo/mock/actions?query=workflow%3ACI) [![codecov](https://codecov.io/gh/udibo/mock/branch/master/graph/badge.svg?token=TXORMSEHM7)](https://codecov.io/gh/udibo/mock) [![license](https://img.shields.io/github/license/udibo/mock)](https://github.com/udibo/mock/blob/master/LICENSE) @@ -30,9 +30,9 @@ imported directly from GitHub using raw content URLs. ```ts // Import from Deno's third party module registry -import { spy, Spy } from "https://deno.land/x/mock@0.12.2/mod.ts"; +import { spy, Spy } from "https://deno.land/x/mock@0.13.0/mod.ts"; // Import from GitHub -import { spy, Spy } "https://raw.githubusercontent.com/udibo/mock/0.12.2/mod.ts"; +import { spy, Spy } "https://raw.githubusercontent.com/udibo/mock/0.13.0/mod.ts"; ``` If you do not need all of the sub-modules, you can choose to just import the @@ -40,12 +40,12 @@ sub-modules you need. ```ts // Import from Deno's third party module registry -import { Spy, spy } from "https://deno.land/x/mock@0.12.2/spy.ts"; +import { Spy, spy } from "https://deno.land/x/mock@0.13.0/spy.ts"; // Import from GitHub import { Spy, spy, -} from "https://raw.githubusercontent.com/udibo/mock/0.12.2/spy.ts"; +} from "https://raw.githubusercontent.com/udibo/mock/0.13.0/spy.ts"; ``` #### Sub-modules @@ -69,7 +69,7 @@ If a Node.js package has the type "module" specified in its package.json file, the JavaScript bundle can be imported as a `.js` file. ```js -import { Spy, spy } from "./mock_0.12.2.js"; +import { Spy, spy } from "./mock_0.13.0.js"; ``` The default type for Node.js packages is "commonjs". To import the bundle into a @@ -77,7 +77,7 @@ commonjs package, the file extension of the JavaScript bundle must be changed from `.js` to `.mjs`. ```js -import { Spy, spy } from "./mock_0.12.2.mjs"; +import { Spy, spy } from "./mock_0.13.0.mjs"; ``` See [Node.js Documentation](https://nodejs.org/api/esm.html) for more @@ -96,7 +96,7 @@ modules must have the type attribute set to "module". ```js // main.js -import { Spy, spy } from "./mock_0.12.2.js"; +import { Spy, spy } from "./mock_0.13.0.js"; ``` You can also embed a module script directly into an HTML file by placing the @@ -104,7 +104,7 @@ JavaScript code within the body of the script tag. ```html ``` @@ -120,7 +120,7 @@ a try block then restore the function in a finally block to ensure the original instance method is restored before continuing to other tests. The same applies when using fake time. -See [deno docs](https://doc.deno.land/https/deno.land/x/mock@0.12.2/mod.ts) for +See [deno docs](https://doc.deno.land/https/deno.land/x/mock@0.13.0/mod.ts) for more information. ### Spy @@ -140,7 +140,7 @@ import { assertSpyCall, Spy, spy, -} from "https://deno.land/x/mock@0.12.2/mod.ts"; +} from "https://deno.land/x/mock@0.13.0/mod.ts"; function add( a: number, @@ -172,7 +172,7 @@ import { assertSpyCalls, Spy, spy, -} from "https://deno.land/x/mock@0.12.2/mod.ts"; +} from "https://deno.land/x/mock@0.13.0/mod.ts"; function filter(values: T[], callback: (value: T) => boolean): any[] { return values.filter(callback); @@ -208,7 +208,7 @@ import { assertSpyCalls, Spy, spy, -} from "https://deno.land/x/mock@0.12.2/mod.ts"; +} from "https://deno.land/x/mock@0.13.0/mod.ts"; class Database { // deno-lint-ignore no-explicit-any @@ -299,7 +299,7 @@ calls made to it. ```ts import { assertEquals } from "https://deno.land/std@0.120.0/testing/asserts.ts"; -import { Stub, stub } from "https://deno.land/x/mock@0.12.2/stub.ts"; +import { Stub, stub } from "https://deno.land/x/mock@0.13.0/stub.ts"; class Cat { action(name: string): any { @@ -343,7 +343,7 @@ import { resolvesNext, Stub, stub, -} from "https://deno.land/x/mock@0.12.2/mod.ts"; +} from "https://deno.land/x/mock@0.13.0/mod.ts"; class Database { query(_query: string, _params: unknown[]): Promise { @@ -420,7 +420,7 @@ Overrides the real Date object and timer functions with fake ones that can be controlled through the fake time instance. ```ts -import { FakeTime, Spy, spy } from "https://deno.land/x/mock@0.12.2/mod.ts"; +import { FakeTime, Spy, spy } from "https://deno.land/x/mock@0.13.0/mod.ts"; function secondInterval(cb: () => void): void { setInterval(cb, 1000); diff --git a/deps.ts b/deps.ts index f0f1932..6e26d29 100644 --- a/deps.ts +++ b/deps.ts @@ -1,5 +1,5 @@ -export { delay } from "https://deno.land/std@0.120.0/async/delay.ts"; -export type { DelayOptions } from "https://deno.land/std@0.120.0/async/delay.ts"; +export { delay } from "https://deno.land/std@0.125.0/async/delay.ts"; +export type { DelayOptions } from "https://deno.land/std@0.125.0/async/delay.ts"; export { assert, @@ -10,7 +10,7 @@ export { assertRejects, assertStrictEquals, assertThrows, -} from "https://deno.land/std@0.120.0/testing/asserts.ts"; +} from "https://deno.land/std@0.125.0/testing/asserts.ts"; export { RBTree } from "https://deno.land/x/collections@0.11.2/trees/rb_tree.ts"; export { ascend } from "https://deno.land/x/collections@0.11.2/comparators.ts";