Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ jobs:

steps:
- uses: actions/checkout@v4
- uses: denoland/setup-deno@v1
- uses: denoland/setup-deno@v2
with:
deno-version: v1.x
deno-version: v2.x
- name: Run tests
run: deno test --allow-env --allow-read=. --allow-net=api.github.com,0.0.0.0,localhost
- name: Deploy to Deno Deploy
Expand Down
5 changes: 0 additions & 5 deletions .vscode/settings.json

This file was deleted.

7 changes: 6 additions & 1 deletion deno.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
{
"importMap": "./import_map.json"
"imports": {
"@std/assert": "jsr:@std/assert@^1.0.12",
"preact": "https://esm.sh/[email protected]?pin=v135",
"preact/": "https://esm.sh/[email protected]&pin=v135/",
"preact-render-to-string": "https://esm.sh/*[email protected]?pin=v135"
}
}
25 changes: 21 additions & 4 deletions deno.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion deps.test.ts

This file was deleted.

4 changes: 2 additions & 2 deletions handleRequest.test.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { assertEquals } from "./deps.test.ts";
import { assertEquals } from "@std/assert";
import { createRequestHandler } from "./handleRequest.ts";
import { RealClock } from "./utils/clock.ts";

const connInfo: Deno.ServeHandlerInfo = {
const connInfo: Deno.ServeHandlerInfo<Deno.NetAddr> = {
remoteAddr: {
transport: "tcp",
hostname: "127.0.0.1",
Expand Down
2 changes: 1 addition & 1 deletion handleRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const contentTypes = {
export function createRequestHandler(clock: Clock) {
const { fetchCached } = createFetchCacher(clock);
return {
async handleRequest(request: Request, info: Deno.ServeHandlerInfo) {
async handleRequest(request: Request, info: Deno.ServeHandlerInfo<Deno.NetAddr>) {
const url = new URL(request.url);
const newUrl = await resolvePluginOrSchemaUrl(url);
if (newUrl != null) {
Expand Down
7 changes: 0 additions & 7 deletions import_map.json

This file was deleted.

2 changes: 1 addition & 1 deletion plugins.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from "./deps.test.ts";
import { assertEquals } from "@std/assert";
import { tryResolveLatestJson } from "./plugins.ts";
import { getLatestReleaseInfo } from "./utils/github.ts";

Expand Down
2 changes: 1 addition & 1 deletion utils/LazyExpirableValue.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals, assertRejects } from "../deps.test.ts";
import { assertEquals, assertRejects } from "@std/assert";
import { LazyExpirableValue } from "./LazyExpirableValue.ts";

Deno.test("should work", async () => {
Expand Down
2 changes: 1 addition & 1 deletion utils/LruCache.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from "../deps.test.ts";
import { assertEquals } from "@std/assert";
import { LruCache, LruCacheWithExpiry } from "./LruCache.ts";

Deno.test("LruCache - keeps only most recent", () => {
Expand Down
2 changes: 1 addition & 1 deletion utils/RateLimiter.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assert } from "../deps.test.ts";
import { assert } from "@std/assert";
import { Clock } from "./clock.ts";
import { RateLimiter } from "./RateLimiter.ts";

Expand Down
2 changes: 1 addition & 1 deletion utils/asyncLazy.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals, assertRejects } from "../deps.test.ts";
import { assertEquals, assertRejects } from "@std/assert";
import { createAsyncLazy } from "./asyncLazy.ts";

Deno.test("should create", async () => {
Expand Down
2 changes: 1 addition & 1 deletion utils/fetchCached.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from "../deps.test.ts";
import { assertEquals } from "@std/assert";
import { createFetchCacher } from "./fetchCached.ts";

Deno.test("should error when going above 10mb", {
Expand Down
2 changes: 1 addition & 1 deletion utils/github.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from "../deps.test.ts";
import { assertEquals } from "@std/assert";
import { checkGithubRepoExists } from "./github.ts";

Deno.test("should get when exists", async () => {
Expand Down
2 changes: 1 addition & 1 deletion utils/version.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from "../deps.test.ts";
import { assertEquals } from "@std/assert";
import { parseVersion, Version } from "./version.ts";

Deno.test("should parse version", () => {
Expand Down