Skip to content

Commit

Permalink
updating snaps
Browse files Browse the repository at this point in the history
Signed-off-by: Amber Torrise <[email protected]>
  • Loading branch information
Amber Torrise committed Mar 14, 2024
1 parent 334554b commit 90a678b
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 64 deletions.
43 changes: 0 additions & 43 deletions __tests__/cli/list/profile-args/ProfileArgs.handler.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,47 +80,4 @@ describe("profile-args Handler", () => {
await handler.process(params);
expect(actualOutput).toMatchObject(expectedOutput);
});

it("should list profile args for old school profiles", async () => {
Object.defineProperty(ImperativeConfig, "instance", {
get: () => ({})
});
const profileArgs = {
host: "fakeHost",
port: 443,
user: "fakeUser",
password: "fakePass",
tshirtSize: "L"
};

const handler = new ProfileArgsHandler.default();
const params = Object.assign({}, ...[DEFAULT_PARAMETERS]);
params.arguments = {...params.arguments, ...profileArgs};
params.profiles = {
getMeta: (name: string) => {
return {
name: "fake" + name.charAt(0).toUpperCase() + name.slice(1)
};
}
};

const expectedOutput = {
arguments: {
...profileArgs,
rejectUnauthorized: true
},
environment: {
usingTeamConfig: false,
sampleProfileName: "fakeSample",
baseProfileName: "fakeBase"
}
};
let actualOutput = null;
params.response.data.setObj.mockImplementation((obj: any) => {
actualOutput = obj;
});

await handler.process(params);
expect(actualOutput).toMatchObject(expectedOutput);
});
});
Original file line number Diff line number Diff line change
@@ -1,26 +1,5 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`profile-args Handler should list profile args for old school profiles 1`] = `
Object {
"format": "object",
"output": Object {
"arguments": Object {
"host": "fakeHost",
"password": "fakePass",
"port": 443,
"rejectUnauthorized": true,
"tshirtSize": "L",
"user": "fakeUser",
},
"environment": Object {
"baseProfileName": "fakeBase",
"sampleProfileName": "fakeSample",
"usingTeamConfig": false,
},
},
}
`;

exports[`profile-args Handler should list profile args for team config 1`] = `
Object {
"format": "object",
Expand Down

0 comments on commit 90a678b

Please sign in to comment.