Skip to main content
Module

x/dectyl/mod.ts

Prototype library for testing Deno Deploy scripts using the Deno CLI
Latest
import * as dectyl from "https://deno.land/x/dectyl@0.10.7/mod.ts";

Functions

Type check a script as if it were a Deploy script, resolving with an array of diagnostic information. If the array is empty, there were no issues with type checking.

Create a web worker which runs the provided module and its dependencies in a Deploy-like environment, and returns an API to interact with the loaded program.

A fetch handler that returns local files that are requested by the worker.

Set the API's logging level. For the worker runtime, this only affects newly created workers.

Asserts that there are no diagnostics returned, otherwise logs the diagnostics to the console and throws.

Asserts a request is effectively equal to the expected information. The options can be used to control the behavior of the comparison.

A helper function that creates a tuple with the information to create a Response object.

Return a request init that mocks what a Chromium request would look like from a client.