@ldo/test-solid-server 1.0.0-alpha.11 → 1.0.0-alpha.9
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/dist/authFetch.d.ts +0 -1
- package/dist/authFetch.js +18 -42
- package/dist/authFetch.js.map +1 -1
- package/dist/createServer.d.ts +1 -1
- package/dist/createServer.js +36 -8
- package/dist/createServer.js.map +1 -1
- package/dist/index.d.ts +3 -4
- package/dist/index.js +19 -3
- package/dist/index.js.map +1 -1
- package/dist/resourceUtils.d.ts +0 -1
- package/dist/resourceUtils.js +7 -2
- package/dist/resourceUtils.js.map +1 -1
- package/dist/setupTestServer.d.ts +6 -5
- package/dist/setupTestServer.js +23 -19
- package/dist/setupTestServer.js.map +1 -1
- package/package.json +2 -4
- package/src/authFetch.ts +2 -9
- package/src/createServer.ts +5 -1
- package/src/index.ts +3 -3
- package/src/setupTestServer.ts +13 -24
- package/dist/authFetch.d.ts.map +0 -1
- package/dist/createServer.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/resourceUtils.d.ts.map +0 -1
- package/dist/setupTestServer.d.ts.map +0 -1
package/dist/authFetch.d.ts
CHANGED
package/dist/authFetch.js
CHANGED
|
@@ -1,21 +1,20 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.generateAuthFetch = void 0;
|
|
7
|
+
const solid_client_authn_core_1 = require("@inrupt/solid-client-authn-core");
|
|
8
|
+
const cross_fetch_1 = __importDefault(require("cross-fetch"));
|
|
3
9
|
const config = {
|
|
4
10
|
podName: "example",
|
|
5
11
|
email: "hello@example.com",
|
|
6
12
|
password: "abc123",
|
|
7
13
|
};
|
|
8
|
-
async function reportError(response) {
|
|
9
|
-
if (response.status >= 400) {
|
|
10
|
-
console.error(await response.text());
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
14
|
async function getAuthorization(port) {
|
|
14
|
-
|
|
15
|
-
const indexResponse = await fetch(`http://localhost:${port}/.account/`);
|
|
15
|
+
const indexResponse = await (0, cross_fetch_1.default)(`http://localhost:${port}/.account/`);
|
|
16
16
|
const { controls } = await indexResponse.json();
|
|
17
|
-
|
|
18
|
-
const response = await fetch(controls.password.login, {
|
|
17
|
+
const response = await (0, cross_fetch_1.default)(controls.password.login, {
|
|
19
18
|
method: "POST",
|
|
20
19
|
headers: { "content-type": "application/json" },
|
|
21
20
|
body: JSON.stringify({
|
|
@@ -23,66 +22,42 @@ async function getAuthorization(port) {
|
|
|
23
22
|
password: config.password,
|
|
24
23
|
}),
|
|
25
24
|
});
|
|
26
|
-
// This authorization value will be used to authenticate in the next step
|
|
27
|
-
await reportError(response);
|
|
28
25
|
const result = await response.json();
|
|
29
26
|
return result.authorization;
|
|
30
27
|
}
|
|
31
28
|
async function getSecret(port, authorization) {
|
|
32
|
-
|
|
33
|
-
// These will now have more values than in the previous example.
|
|
34
|
-
const indexResponse = await fetch(`http://localhost:${port}/.account/`, {
|
|
29
|
+
const indexResponse = await (0, cross_fetch_1.default)(`http://localhost:${port}/.account/`, {
|
|
35
30
|
headers: { authorization: `CSS-Account-Token ${authorization}` },
|
|
36
31
|
});
|
|
37
32
|
const { controls } = await indexResponse.json();
|
|
38
|
-
|
|
39
|
-
const response = await fetch(controls.account.clientCredentials, {
|
|
33
|
+
const response = await (0, cross_fetch_1.default)(controls.account.clientCredentials, {
|
|
40
34
|
method: "POST",
|
|
41
35
|
headers: {
|
|
42
36
|
authorization: `CSS-Account-Token ${authorization}`,
|
|
43
37
|
"content-type": "application/json",
|
|
44
38
|
},
|
|
45
|
-
// The name field will be used when generating the ID of your token.
|
|
46
|
-
// The WebID field determines which WebID you will identify as when using the token.
|
|
47
|
-
// Only WebIDs linked to your account can be used.
|
|
48
39
|
body: JSON.stringify({
|
|
49
40
|
name: "my-token",
|
|
50
41
|
webId: `http://localhost:${port}/${config.podName}/profile/card#me`,
|
|
51
42
|
}),
|
|
52
43
|
});
|
|
53
|
-
await reportError(response);
|
|
54
|
-
// These are the identifier and secret of your token.
|
|
55
|
-
// Store the secret somewhere safe as there is no way to request it again from the server!
|
|
56
|
-
// The `resource` value can be used to delete the token at a later point in time.
|
|
57
44
|
const response2 = await response.json();
|
|
58
45
|
return response2;
|
|
59
46
|
}
|
|
60
47
|
async function getAccessToken(port, id, secret) {
|
|
61
48
|
try {
|
|
62
|
-
|
|
63
|
-
// This function from `solid-client-authn` generates such a pair for you.
|
|
64
|
-
const dpopKey = await generateDpopKeyPair();
|
|
65
|
-
// These are the ID and secret generated in the previous step.
|
|
66
|
-
// Both the ID and the secret need to be form-encoded.
|
|
49
|
+
const dpopKey = await (0, solid_client_authn_core_1.generateDpopKeyPair)();
|
|
67
50
|
const authString = `${encodeURIComponent(id)}:${encodeURIComponent(secret)}`;
|
|
68
|
-
// This URL can be found by looking at the "token_endpoint" field at
|
|
69
|
-
// http://localhost:PORT/.well-known/openid-configuration
|
|
70
|
-
// if your server is hosted at http://localhost:3000/.
|
|
71
51
|
const tokenUrl = `http://localhost:${port}/.oidc/token`;
|
|
72
|
-
const response = await
|
|
52
|
+
const response = await (0, cross_fetch_1.default)(tokenUrl, {
|
|
73
53
|
method: "POST",
|
|
74
54
|
headers: {
|
|
75
|
-
// The header needs to be in base64 encoding.
|
|
76
55
|
authorization: `Basic ${Buffer.from(authString).toString("base64")}`,
|
|
77
56
|
"content-type": "application/x-www-form-urlencoded",
|
|
78
|
-
dpop: await createDpopHeader(tokenUrl, "POST", dpopKey),
|
|
57
|
+
dpop: await (0, solid_client_authn_core_1.createDpopHeader)(tokenUrl, "POST", dpopKey),
|
|
79
58
|
},
|
|
80
59
|
body: "grant_type=client_credentials&scope=webid",
|
|
81
60
|
});
|
|
82
|
-
await reportError(response);
|
|
83
|
-
// This is the Access token that will be used to do an authenticated request to the server.
|
|
84
|
-
// The JSON also contains an "expires_in" field in seconds,
|
|
85
|
-
// which you can use to know when you need request a new Access token.
|
|
86
61
|
const response2 = await response.json();
|
|
87
62
|
return { accessToken: response2.access_token, dpopKey };
|
|
88
63
|
}
|
|
@@ -91,10 +66,11 @@ async function getAccessToken(port, id, secret) {
|
|
|
91
66
|
throw err;
|
|
92
67
|
}
|
|
93
68
|
}
|
|
94
|
-
|
|
69
|
+
async function generateAuthFetch(port) {
|
|
95
70
|
const authorization = await getAuthorization(port);
|
|
96
71
|
const { id, secret } = await getSecret(port, authorization);
|
|
97
72
|
const { accessToken, dpopKey } = await getAccessToken(port, id, secret);
|
|
98
|
-
return await buildAuthenticatedFetch(accessToken, { dpopKey });
|
|
73
|
+
return await (0, solid_client_authn_core_1.buildAuthenticatedFetch)(accessToken, { dpopKey });
|
|
99
74
|
}
|
|
75
|
+
exports.generateAuthFetch = generateAuthFetch;
|
|
100
76
|
//# sourceMappingURL=authFetch.js.map
|
package/dist/authFetch.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authFetch.js","sourceRoot":"","sources":["../src/authFetch.ts"],"names":[],"mappings":"AACA,
|
|
1
|
+
{"version":3,"file":"authFetch.js","sourceRoot":"","sources":["../src/authFetch.ts"],"names":[],"mappings":";;;;;;AACA,6EAIyC;AACzC,8DAAgC;AAEhC,MAAM,MAAM,GAAG;IACb,OAAO,EAAE,SAAS;IAClB,KAAK,EAAE,mBAAmB;IAC1B,QAAQ,EAAE,QAAQ;CACnB,CAAC;AAEF,KAAK,UAAU,gBAAgB,CAAC,IAAY;IAE1C,MAAM,aAAa,GAAG,MAAM,IAAA,qBAAK,EAAC,oBAAoB,IAAI,YAAY,CAAC,CAAC;IACxE,MAAM,EAAE,QAAQ,EAAE,GAAG,MAAM,aAAa,CAAC,IAAI,EAAE,CAAC;IAGhD,MAAM,QAAQ,GAAG,MAAM,IAAA,qBAAK,EAAC,QA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ANGED
package/dist/createServer.js
CHANGED
|
@@ -1,27 +1,55 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
exports.createApp = void 0;
|
|
27
|
+
const path = __importStar(require("path"));
|
|
28
|
+
const community_server_1 = require("@solid/community-server");
|
|
29
|
+
require("jest-rdf");
|
|
30
|
+
jest.setTimeout(40_000);
|
|
31
|
+
async function createApp(port, customConfigPath) {
|
|
5
32
|
if (process.env.SERVER) {
|
|
6
33
|
return {
|
|
7
34
|
start: () => { },
|
|
8
35
|
stop: () => { },
|
|
9
36
|
};
|
|
10
37
|
}
|
|
11
|
-
const appRunner = new AppRunner();
|
|
38
|
+
const appRunner = new community_server_1.AppRunner();
|
|
12
39
|
return appRunner.create({
|
|
13
40
|
loaderProperties: {
|
|
14
|
-
mainModulePath: resolveModulePath(""),
|
|
41
|
+
mainModulePath: (0, community_server_1.resolveModulePath)(""),
|
|
15
42
|
typeChecking: false,
|
|
16
43
|
},
|
|
17
|
-
config: customConfigPath ?? resolveModulePath("config/file-root.json"),
|
|
44
|
+
config: customConfigPath ?? (0, community_server_1.resolveModulePath)("config/file-root.json"),
|
|
18
45
|
variableBindings: {},
|
|
19
46
|
shorthand: {
|
|
20
47
|
port: port,
|
|
21
48
|
loggingLevel: "off",
|
|
22
49
|
seedConfig: path.join(__dirname, "configs", "solid-css-seed.json"),
|
|
23
|
-
rootFilePath: path.join(__dirname,
|
|
50
|
+
rootFilePath: path.join(__dirname, "./data"),
|
|
24
51
|
},
|
|
25
52
|
});
|
|
26
53
|
}
|
|
54
|
+
exports.createApp = createApp;
|
|
27
55
|
//# sourceMappingURL=createServer.js.map
|
package/dist/createServer.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createServer.js","sourceRoot":"","sources":["../src/createServer.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"createServer.js","sourceRoot":"","sources":["../src/createServer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,2CAA6B;AAE7B,8DAAuE;AACvE,oBAAkB;AAGlB,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC;AAEjB,KAAK,UAAU,SAAS,CAC7B,IAAY,EACZ,gBAAyB;IAEzB,IAAI,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,CAAC;QACvB,OAAO;YACL,KAAK,EAAE,GAAG,EAAE,GAAE,CAAC;YACf,IAAI,EAAE,GAAG,EAAE,GAAE,CAAC;SACR,CAAC;IACX,CAAC;IACD,MAAM,SAAS,GAAG,IAAI,4BAAS,EAAE,CAAC;IAElC,OAAO,SAAS,CAAC,MAAM,CAAC;QACtB,gBAAgB,EAAE;YAChB,cAAc,EAAE,IAAA,oCAAiB,EAAC,EAAE,CAAC;YACrC,YAAY,EAAE,KAAK;SACpB;QACD,MAAM,EAAE,gBAAgB,IAAI,IAAA,oCAAiB,EAAC,uBAAuB,CAAC;QACtE,gBAAgB,EAAE,EAAE;QACpB,SAAS,EAAE;YACT,IAAI,EAAE,IAAI;YACV,YAAY,EAAE,KAAK;YACnB,UAAU,EAAE,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,SAAS,EAAE,qBAAqB,CAAC;YAClE,YAAY,EAAE,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,QAAQ,CAAC;SAC7C;KACF,CAAC,CAAC;AACL,CAAC;AA1BD,8BA0BC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
export * from "./createServer
|
|
2
|
-
export * from "./setupTestServer
|
|
3
|
-
export * from "./resourceUtils
|
|
4
|
-
//# sourceMappingURL=index.d.ts.map
|
|
1
|
+
export * from "./createServer";
|
|
2
|
+
export * from "./setupTestServer";
|
|
3
|
+
export * from "./resourceUtils";
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,20 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./createServer"), exports);
|
|
18
|
+
__exportStar(require("./setupTestServer"), exports);
|
|
19
|
+
__exportStar(require("./resourceUtils"), exports);
|
|
4
20
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,iDAA+B;AAC/B,oDAAkC;AAClC,kDAAgC"}
|
package/dist/resourceUtils.d.ts
CHANGED
|
@@ -15,4 +15,3 @@ interface LeafInfo {
|
|
|
15
15
|
export declare function initResources(rootUri: string, resourceInfo: ResourceInfo, authFetch: typeof fetch): Promise<void>;
|
|
16
16
|
export declare function cleanResources(rootUri: string, resourceInfo: ResourceInfo, authFetch: typeof fetch): Promise<void>;
|
|
17
17
|
export {};
|
|
18
|
-
//# sourceMappingURL=resourceUtils.d.ts.map
|
package/dist/resourceUtils.js
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.cleanResources = exports.initResources = void 0;
|
|
4
|
+
async function initResources(rootUri, resourceInfo, authFetch) {
|
|
2
5
|
if (resourceInfo?.shouldNotInit)
|
|
3
6
|
return;
|
|
4
7
|
if (resourceInfo.isContainer) {
|
|
@@ -21,7 +24,8 @@ export async function initResources(rootUri, resourceInfo, authFetch) {
|
|
|
21
24
|
});
|
|
22
25
|
}
|
|
23
26
|
}
|
|
24
|
-
|
|
27
|
+
exports.initResources = initResources;
|
|
28
|
+
async function cleanResources(rootUri, resourceInfo, authFetch) {
|
|
25
29
|
if (resourceInfo.isContainer) {
|
|
26
30
|
await Promise.all(resourceInfo.contains.map((subResourceInfo) => cleanResources(`${rootUri}${resourceInfo.slug}`, subResourceInfo, authFetch)));
|
|
27
31
|
await authFetch(`${rootUri}${resourceInfo.slug}`, {
|
|
@@ -34,4 +38,5 @@ export async function cleanResources(rootUri, resourceInfo, authFetch) {
|
|
|
34
38
|
});
|
|
35
39
|
}
|
|
36
40
|
}
|
|
41
|
+
exports.cleanResources = cleanResources;
|
|
37
42
|
//# sourceMappingURL=resourceUtils.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resourceUtils.js","sourceRoot":"","sources":["../src/resourceUtils.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"resourceUtils.js","sourceRoot":"","sources":["../src/resourceUtils.ts"],"names":[],"mappings":";;;AAiBO,KAAK,UAAU,aAAa,CACjC,OAAe,EACf,YAA0B,EAC1B,SAAuB;IAEvB,IAAI,YAAY,EAAE,aAAa;QAAE,OAAO;IACxC,IAAI,YAAY,CAAC,WAAW,EAAE,CAAC;QAC7B,MAAM,SAAS,CAAC,OAAO,EAAE;YACvB,MAAM,EAAE,MAAM;YACd,OAAO,EAAE;gBACP,IAAI,EAAE,kDAAkD;gBACxD,IAAI,EAAE,YAAY,CAAC,IAAI;aACxB;SACF,CAAC,CAAC;QACH,MAAM,OAAO,CAAC,GAAG,CACf,YAAY,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,eAAe,EAAE,EAAE,CAC5C,aAAa,CACX,GAAG,OAAO,GAAG,YAAY,CAAC,IAAI,EAAE,EAChC,eAAe,EACf,SAAS,CACV,CACF,CACF,CAAC;IACJ,CAAC;SAAM,CAAC;QACN,MAAM,SAAS,CAAC,GAAG,OAAO,GAAG,YAAY,CAAC,IAAI,EAAE,EAAE;YAChD,MAAM,EAAE,KAAK;YACb,OAAO,EAAE;gBACP,cAAc,EAAE,YAAY,CAAC,QAAQ;aACtC;YACD,IAAI,EAAE,YAAY,CAAC,IAAI;SACxB,CAAC,CAAC;IACL,CAAC;AACH,CAAC;AAhCD,sCAgCC;AAEM,KAAK,UAAU,cAAc,CAClC,OAAe,EACf,YAA0B,EAC1B,SAAuB;IAEvB,IAAI,YAAY,CAAC,WAAW,EAAE,CAAC;QAC7B,MAAM,OAAO,CAAC,GAAG,CACf,YAAY,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,eAAe,EAAE,EAAE,CAC5C,cAAc,CACZ,GAAG,OAAO,GAAG,YAAY,CAAC,IAAI,EAAE,EAChC,eAAe,EACf,SAAS,CACV,CACF,CACF,CAAC;QACF,MAAM,SAAS,CAAC,GAAG,OAAO,GAAG,YAAY,CAAC,IAAI,EAAE,EAAE;YAChD,MAAM,EAAE,QAAQ;SACjB,CAAC,CAAC;IACL,CAAC;SAAM,CAAC;QACN,MAAM,SAAS,CAAC,GAAG,OAAO,GAAG,YAAY,CAAC,IAAI,EAAE,EAAE;YAChD,MAAM,EAAE,QAAQ;SACjB,CAAC,CAAC;IACL,CAAC;AACH,CAAC;AAvBD,wCAuBC"}
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import type { App } from "@solid/community-server";
|
|
2
|
-
import type { ResourceInfo } from "./resourceUtils
|
|
3
|
-
|
|
4
|
-
export declare function setupServer(port: number, resourceInfo: ResourceInfo, customConfigPath?: string, skipAuthentication?: boolean): {
|
|
2
|
+
import type { ResourceInfo } from "./resourceUtils";
|
|
3
|
+
export declare function setupServer(port: number, resourceInfo: ResourceInfo, customConfigPath?: string): {
|
|
5
4
|
app: App;
|
|
6
|
-
fetchMock:
|
|
5
|
+
fetchMock: jest.Mock<Promise<Response>, [
|
|
6
|
+
input: RequestInfo | URL,
|
|
7
|
+
init?: RequestInit | undefined
|
|
8
|
+
]>;
|
|
7
9
|
authFetch: typeof fetch;
|
|
8
10
|
rootUri: string;
|
|
9
11
|
};
|
|
10
|
-
//# sourceMappingURL=setupTestServer.d.ts.map
|
package/dist/setupTestServer.js
CHANGED
|
@@ -1,40 +1,44 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.setupServer = void 0;
|
|
7
|
+
const createServer_1 = require("./createServer");
|
|
8
|
+
const path_1 = __importDefault(require("path"));
|
|
9
|
+
const resourceUtils_1 = require("./resourceUtils");
|
|
10
|
+
const authFetch_1 = require("./authFetch");
|
|
11
|
+
const promises_1 = __importDefault(require("fs/promises"));
|
|
12
|
+
function setupServer(port, resourceInfo, customConfigPath) {
|
|
10
13
|
const data = {
|
|
11
14
|
rootUri: `http://localhost:${port}/`,
|
|
12
15
|
};
|
|
13
16
|
let previousJestId;
|
|
14
17
|
let previousNodeEnv;
|
|
15
18
|
beforeAll(async () => {
|
|
16
|
-
|
|
19
|
+
previousJestId = process.env.JEST_WORKER_ID;
|
|
20
|
+
previousNodeEnv = process.env.NODE_ENV;
|
|
21
|
+
delete process.env.JEST_WORKER_ID;
|
|
17
22
|
process.env.NODE_ENV = "other_test";
|
|
18
|
-
|
|
19
|
-
data.app = await createApp(port, customConfigPath);
|
|
23
|
+
data.app = await (0, createServer_1.createApp)(port, customConfigPath);
|
|
20
24
|
await data.app.start();
|
|
21
|
-
data.authFetch =
|
|
25
|
+
data.authFetch = await (0, authFetch_1.generateAuthFetch)(port);
|
|
22
26
|
});
|
|
23
27
|
afterAll(async () => {
|
|
24
28
|
data.app.stop();
|
|
25
29
|
process.env.JEST_WORKER_ID = previousJestId;
|
|
26
30
|
process.env.NODE_ENV = previousNodeEnv;
|
|
27
|
-
const testDataPath =
|
|
28
|
-
await
|
|
31
|
+
const testDataPath = path_1.default.join(__dirname, "./data");
|
|
32
|
+
await promises_1.default.rm(testDataPath, { recursive: true, force: true });
|
|
29
33
|
});
|
|
30
34
|
beforeEach(async () => {
|
|
31
|
-
data.fetchMock =
|
|
32
|
-
|
|
33
|
-
await initResources(data.rootUri, resourceInfo, data.authFetch);
|
|
35
|
+
data.fetchMock = jest.fn(data.authFetch);
|
|
36
|
+
await (0, resourceUtils_1.initResources)(data.rootUri, resourceInfo, data.authFetch);
|
|
34
37
|
});
|
|
35
38
|
afterEach(async () => {
|
|
36
|
-
await cleanResources(data.rootUri, resourceInfo, data.authFetch);
|
|
39
|
+
await (0, resourceUtils_1.cleanResources)(data.rootUri, resourceInfo, data.authFetch);
|
|
37
40
|
});
|
|
38
41
|
return data;
|
|
39
42
|
}
|
|
43
|
+
exports.setupServer = setupServer;
|
|
40
44
|
//# sourceMappingURL=setupTestServer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setupTestServer.js","sourceRoot":"","sources":["../src/setupTestServer.ts"],"names":[],"mappings":"AAEA,
|
|
1
|
+
{"version":3,"file":"setupTestServer.js","sourceRoot":"","sources":["../src/setupTestServer.ts"],"names":[],"mappings":";;;;;;AAEA,iDAA2C;AAC3C,gDAAwB;AAExB,mDAAgE;AAChE,2CAAgD;AAChD,2DAA6B;AAE7B,SAAgB,WAAW,CACzB,IAAY,EACZ,YAA0B,EAC1B,gBAAyB;IAEzB,MAAM,IAAI,GAQN;QACF,OAAO,EAAE,oBAAoB,IAAI,GAAG;KAC9B,CAAC;IAET,IAAI,cAAkC,CAAC;IACvC,IAAI,eAAmC,CAAC;IACxC,SAAS,CAAC,KAAK,IAAI,EAAE;QAEnB,cAAc,GAAG,OAAO,CAAC,GAAG,CAAC,cAAc,CAAC;QAC5C,eAAe,GAAG,OAAO,CAAC,GAAG,CAAC,QA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.json
CHANGED
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ldo/test-solid-server",
|
|
3
|
-
"version": "1.0.0-alpha.
|
|
3
|
+
"version": "1.0.0-alpha.9",
|
|
4
4
|
"description": "A solid server to be used in jest tests",
|
|
5
|
-
"type": "module",
|
|
6
5
|
"main": "dist/index.js",
|
|
7
|
-
"module": "dist/index.js",
|
|
8
6
|
"scripts": {
|
|
9
7
|
"build": "tsc --project tsconfig.build.json && npm run copy-configs",
|
|
10
8
|
"prepublishOnly": "npm run build",
|
|
@@ -33,5 +31,5 @@
|
|
|
33
31
|
"publishConfig": {
|
|
34
32
|
"access": "public"
|
|
35
33
|
},
|
|
36
|
-
"gitHead": "
|
|
34
|
+
"gitHead": "54f83580d3dbeaeadaabb14a45cac49f26892ecb"
|
|
37
35
|
}
|
package/src/authFetch.ts
CHANGED
|
@@ -12,12 +12,6 @@ const config = {
|
|
|
12
12
|
password: "abc123",
|
|
13
13
|
};
|
|
14
14
|
|
|
15
|
-
async function reportError(response: Response) {
|
|
16
|
-
if (response.status >= 400) {
|
|
17
|
-
console.error(await response.text());
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
|
|
21
15
|
async function getAuthorization(port: number): Promise<string> {
|
|
22
16
|
// First we request the account API controls to find out where we can log in
|
|
23
17
|
const indexResponse = await fetch(`http://localhost:${port}/.account/`);
|
|
@@ -33,7 +27,6 @@ async function getAuthorization(port: number): Promise<string> {
|
|
|
33
27
|
}),
|
|
34
28
|
});
|
|
35
29
|
// This authorization value will be used to authenticate in the next step
|
|
36
|
-
await reportError(response);
|
|
37
30
|
const result = await response.json();
|
|
38
31
|
return result.authorization;
|
|
39
32
|
}
|
|
@@ -64,7 +57,7 @@ async function getSecret(
|
|
|
64
57
|
webId: `http://localhost:${port}/${config.podName}/profile/card#me`,
|
|
65
58
|
}),
|
|
66
59
|
});
|
|
67
|
-
|
|
60
|
+
|
|
68
61
|
// These are the identifier and secret of your token.
|
|
69
62
|
// Store the secret somewhere safe as there is no way to request it again from the server!
|
|
70
63
|
// The `resource` value can be used to delete the token at a later point in time.
|
|
@@ -101,7 +94,7 @@ async function getAccessToken(
|
|
|
101
94
|
},
|
|
102
95
|
body: "grant_type=client_credentials&scope=webid",
|
|
103
96
|
});
|
|
104
|
-
|
|
97
|
+
|
|
105
98
|
// This is the Access token that will be used to do an authenticated request to the server.
|
|
106
99
|
// The JSON also contains an "expires_in" field in seconds,
|
|
107
100
|
// which you can use to know when you need request a new Access token.
|
package/src/createServer.ts
CHANGED
|
@@ -3,6 +3,10 @@
|
|
|
3
3
|
import * as path from "path";
|
|
4
4
|
import type { App } from "@solid/community-server";
|
|
5
5
|
import { AppRunner, resolveModulePath } from "@solid/community-server";
|
|
6
|
+
import "jest-rdf";
|
|
7
|
+
|
|
8
|
+
// Use an increased timeout, since the CSS server takes too much setup time.
|
|
9
|
+
jest.setTimeout(40_000);
|
|
6
10
|
|
|
7
11
|
export async function createApp(
|
|
8
12
|
port: number,
|
|
@@ -27,7 +31,7 @@ export async function createApp(
|
|
|
27
31
|
port: port,
|
|
28
32
|
loggingLevel: "off",
|
|
29
33
|
seedConfig: path.join(__dirname, "configs", "solid-css-seed.json"),
|
|
30
|
-
rootFilePath: path.join(__dirname,
|
|
34
|
+
rootFilePath: path.join(__dirname, "./data"),
|
|
31
35
|
},
|
|
32
36
|
});
|
|
33
37
|
}
|
package/src/index.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from "./createServer
|
|
2
|
-
export * from "./setupTestServer
|
|
3
|
-
export * from "./resourceUtils
|
|
1
|
+
export * from "./createServer";
|
|
2
|
+
export * from "./setupTestServer";
|
|
3
|
+
export * from "./resourceUtils";
|
package/src/setupTestServer.ts
CHANGED
|
@@ -1,36 +1,22 @@
|
|
|
1
1
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
2
2
|
import type { App } from "@solid/community-server";
|
|
3
|
-
import { createApp } from "./createServer
|
|
3
|
+
import { createApp } from "./createServer";
|
|
4
4
|
import path from "path";
|
|
5
|
-
import type { ResourceInfo } from "./resourceUtils
|
|
6
|
-
import { cleanResources, initResources } from "./resourceUtils
|
|
7
|
-
import { generateAuthFetch } from "./authFetch
|
|
5
|
+
import type { ResourceInfo } from "./resourceUtils";
|
|
6
|
+
import { cleanResources, initResources } from "./resourceUtils";
|
|
7
|
+
import { generateAuthFetch } from "./authFetch";
|
|
8
8
|
import fs from "fs/promises";
|
|
9
|
-
import {
|
|
10
|
-
beforeAll,
|
|
11
|
-
afterAll,
|
|
12
|
-
beforeEach,
|
|
13
|
-
afterEach,
|
|
14
|
-
vi,
|
|
15
|
-
type MockedFunction,
|
|
16
|
-
} from "vitest";
|
|
17
|
-
|
|
18
|
-
// Use an increased timeout, since the CSS server takes too much setup time.
|
|
19
|
-
vi.setConfig({ testTimeout: 40_000 });
|
|
20
9
|
|
|
21
10
|
export function setupServer(
|
|
22
11
|
port: number,
|
|
23
12
|
resourceInfo: ResourceInfo,
|
|
24
13
|
customConfigPath?: string,
|
|
25
|
-
skipAuthentication?: boolean,
|
|
26
14
|
) {
|
|
27
15
|
const data: {
|
|
28
16
|
app: App;
|
|
29
|
-
fetchMock:
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
init?: RequestInit | undefined,
|
|
33
|
-
) => Promise<Response>
|
|
17
|
+
fetchMock: jest.Mock<
|
|
18
|
+
Promise<Response>,
|
|
19
|
+
[input: RequestInfo | URL, init?: RequestInit | undefined]
|
|
34
20
|
>;
|
|
35
21
|
authFetch: typeof fetch;
|
|
36
22
|
rootUri: string;
|
|
@@ -42,23 +28,26 @@ export function setupServer(
|
|
|
42
28
|
let previousNodeEnv: string | undefined;
|
|
43
29
|
beforeAll(async () => {
|
|
44
30
|
// Remove Jest ID so that community solid server doesn't use the Jest Import
|
|
31
|
+
previousJestId = process.env.JEST_WORKER_ID;
|
|
32
|
+
previousNodeEnv = process.env.NODE_ENV;
|
|
33
|
+
delete process.env.JEST_WORKER_ID;
|
|
45
34
|
process.env.NODE_ENV = "other_test";
|
|
46
35
|
// Start up the server
|
|
47
36
|
data.app = await createApp(port, customConfigPath);
|
|
48
37
|
await data.app.start();
|
|
49
|
-
data.authFetch =
|
|
38
|
+
data.authFetch = await generateAuthFetch(port);
|
|
50
39
|
});
|
|
51
40
|
|
|
52
41
|
afterAll(async () => {
|
|
53
42
|
data.app.stop();
|
|
54
43
|
process.env.JEST_WORKER_ID = previousJestId;
|
|
55
44
|
process.env.NODE_ENV = previousNodeEnv;
|
|
56
|
-
const testDataPath = path.join(__dirname,
|
|
45
|
+
const testDataPath = path.join(__dirname, "./data");
|
|
57
46
|
await fs.rm(testDataPath, { recursive: true, force: true });
|
|
58
47
|
});
|
|
59
48
|
|
|
60
49
|
beforeEach(async () => {
|
|
61
|
-
data.fetchMock =
|
|
50
|
+
data.fetchMock = jest.fn(data.authFetch);
|
|
62
51
|
// Create a new document called sample.ttl
|
|
63
52
|
await initResources(data.rootUri, resourceInfo, data.authFetch);
|
|
64
53
|
});
|
package/dist/authFetch.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"authFetch.d.ts","sourceRoot":"","sources":["../src/authFetch.ts"],"names":[],"mappings":"AAmHA,wBAAsB,iBAAiB,CAAC,IAAI,EAAE,MAAM,oCAKnD"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"createServer.d.ts","sourceRoot":"","sources":["../src/createServer.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,yBAAyB,CAAC;AAGnD,wBAAsB,SAAS,CAC7B,IAAI,EAAE,MAAM,EACZ,gBAAgB,CAAC,EAAE,MAAM,GACxB,OAAO,CAAC,GAAG,CAAC,CAuBd"}
|
package/dist/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"resourceUtils.d.ts","sourceRoot":"","sources":["../src/resourceUtils.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,GAAG,aAAa,GAAG,QAAQ,CAAC;AAEpD,UAAU,aAAa;IACrB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,IAAI,CAAC;IAClB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,QAAQ,EAAE,CAAC,aAAa,GAAG,QAAQ,CAAC,EAAE,CAAC;CACxC;AAED,UAAU,QAAQ;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,KAAK,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,wBAAsB,aAAa,CACjC,OAAO,EAAE,MAAM,EACf,YAAY,EAAE,YAAY,EAC1B,SAAS,EAAE,OAAO,KAAK,GACtB,OAAO,CAAC,IAAI,CAAC,CA4Bf;AAED,wBAAsB,cAAc,CAClC,OAAO,EAAE,MAAM,EACf,YAAY,EAAE,YAAY,EAC1B,SAAS,EAAE,OAAO,KAAK,GACtB,OAAO,CAAC,IAAI,CAAC,CAmBf"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"setupTestServer.d.ts","sourceRoot":"","sources":["../src/setupTestServer.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,yBAAyB,CAAC;AAGnD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAIvD,OAAO,EAML,KAAK,cAAc,EACpB,MAAM,QAAQ,CAAC;AAKhB,wBAAgB,WAAW,CACzB,IAAI,EAAE,MAAM,EACZ,YAAY,EAAE,YAAY,EAC1B,gBA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