mirror of
https://github.com/Azure/k8s-deploy.git
synced 2026-06-22 19:59:26 +08:00
18 lines
572 B
TypeScript
18 lines
572 B
TypeScript
import { prefixObjectKeys } from "../utilities/workflowAnnotationUtils";
|
|
|
|
describe("WorkflowAnnotationUtils", () => {
|
|
describe("prefixObjectKeys", () => {
|
|
it("should prefix an object with a given prefix", () => {
|
|
const obj = {
|
|
foo: "bar",
|
|
baz: "qux",
|
|
};
|
|
const prefix = "prefix.";
|
|
const expected = {
|
|
"prefix.foo": "bar",
|
|
"prefix.baz": "qux",
|
|
};
|
|
expect(prefixObjectKeys(obj, prefix)).toEqual(expected);
|
|
});
|
|
});
|
|
}); |