@pod-os/core 0.31.0-rc.e4f8536.0 → 0.31.0-rc.ec58f15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pod-os/core",
|
|
3
3
|
"description": "Core module of PodOS",
|
|
4
|
-
"version": "0.31.0-rc.
|
|
4
|
+
"version": "0.31.0-rc.ec58f15.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
7
7
|
"types": "./types/index.d.ts",
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
"node": ">=18.0.0"
|
|
22
22
|
},
|
|
23
23
|
"scripts": {
|
|
24
|
-
"test": "
|
|
25
|
-
"test:watch": "
|
|
24
|
+
"test": "vitest --watch=false",
|
|
25
|
+
"test:watch": "vitest",
|
|
26
26
|
"typecheck": "tsc --noEmit",
|
|
27
27
|
"lint": "eslint ./src",
|
|
28
28
|
"build:bundle": "rimraf lib && node esbuild/build-bundle.mjs",
|
|
@@ -49,8 +49,6 @@
|
|
|
49
49
|
"@types/sparqljs": "^3.1.12",
|
|
50
50
|
"esbuild": "^0.28.0",
|
|
51
51
|
"eslint": "^10.0.0",
|
|
52
|
-
"jest": "^30.4.2",
|
|
53
|
-
"jest-when": "^4.0.3",
|
|
54
52
|
"npm-run-all": "^4.1.5",
|
|
55
53
|
"prettier": "^3.8.3",
|
|
56
54
|
"rimraf": "^6.1.3",
|
|
@@ -58,7 +56,9 @@
|
|
|
58
56
|
"typedoc": "^0.28.19",
|
|
59
57
|
"typedoc-plugin-markdown": "^4.11.0",
|
|
60
58
|
"typescript": "^6.0.3",
|
|
61
|
-
"typescript-eslint": "^8.59.4"
|
|
59
|
+
"typescript-eslint": "^8.59.4",
|
|
60
|
+
"vitest": "^4.1.8",
|
|
61
|
+
"vitest-when": "^0.10.0"
|
|
62
62
|
},
|
|
63
63
|
"dependencies": {
|
|
64
64
|
"@solid-data-modules/rdflib-utils": "^0.6.0",
|
package/types/Store.spec.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare function thenSparqlUpdateIsSentToUrl(fetchMock:
|
|
1
|
+
import { Mock } from "vitest";
|
|
2
|
+
export declare function thenSparqlUpdateIsSentToUrl(fetchMock: Mock, url: string, query: string): void;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Mock } from "vitest";
|
|
2
|
+
/**
|
|
3
|
+
* Expect that a PATCH request has been performed
|
|
4
|
+
* @param authenticatedFetch - A mocked fetch function
|
|
5
|
+
* @param url - The expected URL to PATCH
|
|
6
|
+
* @param expectedBody - The expected request body
|
|
7
|
+
*/
|
|
8
|
+
export declare function expectPatchRequest(authenticatedFetch: Mock, url: string, expectedBody: string): void;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { Mock } from "vitest";
|
|
2
|
+
/**
|
|
3
|
+
* Mock a turtle document at the given URL
|
|
4
|
+
* @param fetch - A mocked fetch function
|
|
5
|
+
* @param url - The URL to mock
|
|
6
|
+
* @param ttl - The mocked turtle file content
|
|
7
|
+
* @param additionalHeaders - Additional headers to include in the response
|
|
8
|
+
*/
|
|
9
|
+
export declare function mockTurtleDocument(fetch: Mock, url: string, ttl: string, additionalHeaders?: Record<string, string>): void;
|
|
10
|
+
/**
|
|
11
|
+
* Mock a LDP container at the given URL
|
|
12
|
+
* @param fetch - A mocked fetch function
|
|
13
|
+
* @param url - The URL to mock
|
|
14
|
+
* @param contains - List of URLs of documents contained in this container
|
|
15
|
+
* @param moreTurtle - Additional turtle to include into the response
|
|
16
|
+
* @param additionalHeaders - Additional headers to include in the response
|
|
17
|
+
*/
|
|
18
|
+
export declare function mockLdpContainer(fetch: Mock, url: string, contains?: string[], moreTurtle?: string, additionalHeaders?: Record<string, string>): void;
|
|
19
|
+
/**
|
|
20
|
+
* Mock a 404 - Not Found response for the given URL
|
|
21
|
+
* @param fetch - A mocked fetch function
|
|
22
|
+
* @param url - The URL to mock
|
|
23
|
+
*/
|
|
24
|
+
export declare function mockNotFound(fetch: Mock, url: string): void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|