Skip to content

armgit / hypit

Public Imported from GitHub
0

Clone any viral video with AI agents. Not just a script, the whole workflow: swap the face, the words, the B-roll, ship 100 variants in one command, and get your 100M views.

704 B
Raw Blame
import assert from "node:assert/strict";
import test from "node:test";

import { EnvironmentCredentialStore } from "@hypit/credential-store-env";
import { credentialRef } from "@hypit/runtime";

test("environment credentials resolve only the explicitly requested key", async () => {
  const store = new EnvironmentCredentialStore({
    PROVIDER_KEY: "secret-value",
    UNRELATED_SECRET: "must-not-be-enumerated",
  });
  assert.deepEqual(await store.resolve(credentialRef("env", "PROVIDER_KEY")), {
    secret: "secret-value",
  });
  assert.equal(await store.resolve(credentialRef("env", "MISSING")), undefined);
  assert.equal(await store.resolve(credentialRef("os", "PROVIDER_KEY")), undefined);
});