@coffre/conformance 0.6.1 → 0.6.2

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/main.js CHANGED
@@ -204,7 +204,8 @@ function createClient(options) {
204
204
  projects: {
205
205
  /** With their environments. */
206
206
  list: () => call("GET /projects", {}),
207
- create: (project, input) => call("PUT /projects/:project", { project }, input),
207
+ /** Its `name`, which releases before 0.6.2 show, defaults to the slug. */
208
+ create: (project, input = {}) => call("PUT /projects/:project", { project }, input),
208
209
  update: (project, patch) => call("PATCH /projects/:project", { project }, patch),
209
210
  /** What deleting an archived project would erase and revoke; changes nothing. */
210
211
  previewDelete: (project) => {
@@ -215,7 +216,8 @@ function createClient(options) {
215
216
  delete: (project) => call("DELETE /projects/:project", { project })
216
217
  },
217
218
  environments: {
218
- create: (path, input) => call("PUT /projects/:project/:environment", place(path), input),
219
+ /** As a project's: its `name` defaults to the slug. `from` forks a sibling. */
220
+ create: (path, input = {}) => call("PUT /projects/:project/:environment", place(path), input),
219
221
  update: (path, patch) => call("PATCH /projects/:project/:environment", place(path), patch),
220
222
  /** What deleting an archived environment would erase and revoke; changes nothing. */
221
223
  previewDelete: (path) => {
@@ -3910,22 +3912,22 @@ const PAGES = [
3910
3912
  ],
3911
3913
  [
3912
3914
  `/projects/${PROJECT$1}`,
3913
- "Conformance",
3915
+ PROJECT$1,
3914
3916
  "Environments"
3915
3917
  ],
3916
3918
  [
3917
3919
  `/projects/${PROJECT$1}/users`,
3918
- "Conformance",
3920
+ PROJECT$1,
3919
3921
  "Users"
3920
3922
  ],
3921
3923
  [
3922
3924
  `/projects/${PROJECT$1}/service-accounts`,
3923
- "Conformance",
3925
+ PROJECT$1,
3924
3926
  "Service accounts"
3925
3927
  ],
3926
3928
  [
3927
3929
  `/projects/${PROJECT$1}/settings`,
3928
- "Conformance",
3930
+ PROJECT$1,
3929
3931
  "Settings"
3930
3932
  ],
3931
3933
  [
@@ -4186,7 +4188,7 @@ const typeLines = (steps) => `(async () => {
4186
4188
  node.dispatchEvent(new Event('input', { bubbles: true }));
4187
4189
  node.setSelectionRange(text.length, text.length);
4188
4190
  };
4189
- button('New secret')?.click();
4191
+ button('Add secret')?.click();
4190
4192
  const named = await shown('Name of the new secret');
4191
4193
  if (named === null) return { field: null };
4192
4194
  typed(named, name);
@@ -4228,7 +4230,7 @@ async function pastedValues(deployment, admin, browser) {
4228
4230
  try {
4229
4231
  const caret = added.length;
4230
4232
  const adding = await chrome.load(page, admin.browser.cookies(), void 0, pasteInto({
4231
- open: "New secret",
4233
+ open: "Add secret",
4232
4234
  name: "PASTED_KEY",
4233
4235
  field: "Value for PASTED_KEY",
4234
4236
  text: added,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@coffre/conformance",
3
- "version": "0.6.1",
3
+ "version": "0.6.2",
4
4
  "description": "Checks a coffre deployment from outside: what it must never do, whatever code it runs.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -31,8 +31,8 @@
31
31
  "dependencies": {
32
32
  "jose": "6.2.3",
33
33
  "pg": "8.16.3",
34
- "@coffre/db": "0.6.1",
35
- "@coffre/cli": "0.6.1"
34
+ "@coffre/cli": "0.6.2",
35
+ "@coffre/db": "0.6.2"
36
36
  },
37
37
  "devDependencies": {
38
38
  "@types/node": "26.1.1",
@@ -41,7 +41,7 @@
41
41
  "tsdown": "0.23.0",
42
42
  "typescript": "5.9.3",
43
43
  "vite": "8.1.5",
44
- "@coffre/client": "0.6.1"
44
+ "@coffre/client": "0.6.2"
45
45
  },
46
46
  "scripts": {
47
47
  "build": "tsdown",
@@ -14,10 +14,10 @@ import { DEV, type Person, PROJECT, signIn } from './people.ts';
14
14
  /** Each page, the heading it shows, and the tab it is, for a page with tabs. */
15
15
  const PAGES: [path: string, heading: string, tab: string | null][] = [
16
16
  ['/projects', 'Projects', null],
17
- [`/projects/${PROJECT}`, 'Conformance', 'Environments'],
18
- [`/projects/${PROJECT}/users`, 'Conformance', 'Users'],
19
- [`/projects/${PROJECT}/service-accounts`, 'Conformance', 'Service accounts'],
20
- [`/projects/${PROJECT}/settings`, 'Conformance', 'Settings'],
17
+ [`/projects/${PROJECT}`, PROJECT, 'Environments'],
18
+ [`/projects/${PROJECT}/users`, PROJECT, 'Users'],
19
+ [`/projects/${PROJECT}/service-accounts`, PROJECT, 'Service accounts'],
20
+ [`/projects/${PROJECT}/settings`, PROJECT, 'Settings'],
21
21
  ['/audit', 'Audit', null],
22
22
  ];
23
23
 
@@ -117,7 +117,7 @@ export async function pagesInBrowser(deployment: Deployment, admin: Person, brow
117
117
  const then = path === account ? openFromMenu('button[aria-label^="Actions for"]', 'Remove') : undefined;
118
118
  const loaded = await chrome.load(new URL(path, deployment.origin).href, admin.browser.cookies(), undefined, then);
119
119
  expect(loaded.errors.length === 0, `${path}, signed in, reported errors in the browser`, loaded.errors.join('\n'));
120
- // The heading, then what may follow it in the h1, such as a project's slug.
120
+ // The heading, then what may follow it in the h1.
121
121
  expect(loaded.heading?.startsWith(heading), `${path}, signed in, shows ${JSON.stringify(loaded.heading)}, not the heading ${JSON.stringify(heading)}`);
122
122
  expect(loaded.tab === tab, `${path}, signed in, shows the tab ${JSON.stringify(loaded.tab)}, not ${JSON.stringify(tab)}`);
123
123
  if (path.startsWith('/service-accounts')) expect(!/(?<![\w-])token:[A-Za-z0-9]/.test(loaded.text), `${path} shows a service account as token:<name>`, loaded.text);
@@ -235,7 +235,7 @@ const typeLines = (steps: { name: string; field: string; first: string; second:
235
235
  node.dispatchEvent(new Event('input', { bubbles: true }));
236
236
  node.setSelectionRange(text.length, text.length);
237
237
  };
238
- button('New secret')?.click();
238
+ button('Add secret')?.click();
239
239
  const named = await shown('Name of the new secret');
240
240
  if (named === null) return { field: null };
241
241
  typed(named, name);
@@ -277,7 +277,7 @@ export async function pastedValues(deployment: Deployment, admin: Person, browse
277
277
  const chrome = await Chrome.open(executable);
278
278
  try {
279
279
  const caret = added.length;
280
- const adding = await chrome.load(page, admin.browser.cookies(), undefined, pasteInto({ open: 'New secret', name: 'PASTED_KEY', field: 'Value for PASTED_KEY', text: added, save: 'Save PASTED_KEY now' }));
280
+ const adding = await chrome.load(page, admin.browser.cookies(), undefined, pasteInto({ open: 'Add secret', name: 'PASTED_KEY', field: 'Value for PASTED_KEY', text: added, save: 'Save PASTED_KEY now' }));
281
281
  expect(adding.errors.length === 0, `${page} reported errors in the browser`, adding.errors.join('\n'));
282
282
  expect(
283
283
  JSON.stringify(adding.answer) === JSON.stringify({ field: 'textarea', label: 'Value for PASTED_KEY', caret: [caret, caret] }),