Unified · Split
| @@ -83,9 +83,11 @@ describe("file secrets data directory", () => { · 82 unmodified lines | |||
| 83 | const authPath = first.executor.fileSecrets.filePath; | 83 | const authPath = first.executor.fileSecrets.filePath; |
| 84 | expect(authPath).toBe(join(dataDir, "auth.json")); | 84 | expect(authPath).toBe(join(dataDir, "auth.json")); |
| 85 | expect(existsSync(authPath)).toBe(true); | 85 | expect(existsSync(authPath)).toBe(true); |
| 86 | expect(readFileSync(authPath, "utf8")).toContain( | 86 | const storedCredentials = readFileSync(authPath, "utf8"); |
| 87 | '"connection:org:durable-secrets:main:token": "secret-token"', | 87 | expect(storedCredentials).toMatch( |
| 88 | /"connection:org:durable-secrets:main:[^"]+:token": "secret-token"/, | ||
| 88 | ); | 89 | ); |
| 90 | expect(storedCredentials).not.toContain('"connection:org:durable-secrets:main:token"'); | ||
| 89 | expect(existsSync(join(dataDir, "test.db"))).toBe(true); | 91 | expect(existsSync(join(dataDir, "test.db"))).toBe(true); |
| 90 | return authPath; | 92 | return authPath; |
| 91 | }), | 93 | }), |