Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove the 'zowe profiles' command group #2013

Merged
merged 70 commits into from
Jan 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
70 commits
Select commit Hold shift + click to select a range
7a1eaab
No longer add profile group into cmd tree within Imperative.addAutoGe…
gejohnston Nov 30, 2023
54bbc36
Set profiles directory even though we don't create it
gejohnston Dec 4, 2023
ce80341
Alter tests for removal of BasicProfileManager.initialize()
gejohnston Dec 4, 2023
5023d9d
Merge remote-tracking branch 'origin/next' into no-v1-profiles
gejohnston Dec 4, 2023
cec611c
Remove unused imports
gejohnston Dec 4, 2023
ea34b87
Fix tests for removal of CompleteProfilesGroupBuilder
gejohnston Dec 4, 2023
cf6995f
Reduce command count from 3 to 2 due to removed profiles group
gejohnston Dec 4, 2023
9831531
Use config not v1 profiles in tests - round 1
gejohnston Dec 6, 2023
01a42ce
Remove tests of v1 profiles - round 1
gejohnston Dec 7, 2023
79aca74
Replace 'source' with '.'
gejohnston Dec 12, 2023
af8d59f
Replace bash-style function with sh-style function.
gejohnston Dec 12, 2023
77861de
Replace v1 profile commands with team config files
gejohnston Dec 13, 2023
f79a0a4
Remove profile creation from a profile read test
gejohnston Dec 14, 2023
1fba202
Remove test of 'profiles list' command.
gejohnston Dec 14, 2023
1210730
Remove tests that write V1 profiles
gejohnston Dec 14, 2023
acbb5ef
Use pre-existing profile files not v1 profile cmds
gejohnston Dec 15, 2023
343af43
Use pre-existing profile files not v1 profile cmds - BasicProfileManager
gejohnston Dec 18, 2023
8f6ca66
Remove profile commands from tests - Cmd.cli.root
gejohnston Dec 18, 2023
9d203ec
Remove tests of profile commands
gejohnston Dec 20, 2023
be9c42a
Use pre-existing profile files not v1 profile cmds - CliProfileManage…
gejohnston Dec 20, 2023
2f8e68d
Add certFile and certKeyFile to expected schema
gejohnston Dec 20, 2023
6e0c894
Remove "profiles" command from help snapshot
gejohnston Dec 20, 2023
7d1d4c6
Use pre-existing profile files not v1 profile cmds - AutoGeneratedPro…
gejohnston Dec 21, 2023
40f4868
create.secured-profile subtest was removed, so don't require it
gejohnston Dec 21, 2023
33ca087
Replace profile commands with config init, config list, and config set
gejohnston Jan 2, 2024
7ab146e
Replace profile commands with pre-created profile files and keyring.s…
gejohnston Jan 3, 2024
eed308b
Removed obsolete snapshots
gejohnston Jan 3, 2024
a7c7675
Attempt fixes for system tests
awharn Jan 4, 2024
45c6d03
Change expect
awharn Jan 4, 2024
aaba492
Try parsing the JSON
awharn Jan 5, 2024
1d8690a
Additional test fixes
awharn Jan 5, 2024
a058980
Add changelog entry
gejohnston Jan 5, 2024
d703e34
Replace profile commands with pre-created team config
gejohnston Jan 5, 2024
0314cc8
Fix more system tests
awharn Jan 5, 2024
b4f3f04
Fix indent
awharn Jan 5, 2024
48d43b9
Fix copy paste errors
awharn Jan 5, 2024
b1d1564
Merge remote-tracking branch 'origin/next' into no-v1-profiles
gejohnston Jan 5, 2024
c4e00c1
Update tests again
awharn Jan 5, 2024
101ba64
Merge remote-tracking branch 'origin/update-system-tests' into no-v1-…
gejohnston Jan 5, 2024
a8326b0
Fix lint errors.
gejohnston Jan 5, 2024
92214da
Retain as much of the original error as possible
awharn Jan 8, 2024
787ba15
Fix status checks
awharn Jan 8, 2024
efdffce
Update pacote
awharn Jan 8, 2024
93fd878
Attempt more test fixes
awharn Jan 8, 2024
6d455b6
Add causeErrors.message as another source of error message.
gejohnston Jan 8, 2024
ce88630
Merge remote-tracking branch 'origin/no-v1-profiles' into update-syst…
awharn Jan 8, 2024
b179da5
Revert changes
awharn Jan 8, 2024
3896115
Resolve extra parsing
awharn Jan 8, 2024
ba51c26
Update snapshots and tests
awharn Jan 8, 2024
c4770b3
Adjust test for new error format.
gejohnston Jan 8, 2024
abbd83f
Additional changes
awharn Jan 8, 2024
57594f1
Replace snapshots with tests for actual errors
gejohnston Jan 8, 2024
8b883a2
Merge remote-tracking branch 'origin/next' into no-v1-profiles
gejohnston Jan 8, 2024
cbe1e36
Fix the remaining tests
awharn Jan 8, 2024
5775c29
Merge remote-tracking branch 'origin/update-system-tests' into no-v1-…
gejohnston Jan 8, 2024
6ff5779
Merge remote-tracking branch 'origin/update-system-tests' into no-v1-…
gejohnston Jan 8, 2024
00eacec
Add changelog entries
gejohnston Jan 9, 2024
6908828
System test debug hacks for create_team_cfg.sh
gejohnston Jan 9, 2024
1ddd317
Disable lint error on debug hack
gejohnston Jan 9, 2024
eaaa49f
Add quotes around Jenkins spacey directory path
gejohnston Jan 9, 2024
c85d5a7
Avoid using `dirname` with a spacey path
gejohnston Jan 9, 2024
3146ab4
Remove system test debug hacks
gejohnston Jan 9, 2024
e57fa08
Remove unused variables.
gejohnston Jan 10, 2024
04e7588
Add entry about profile removal to CLI CHANGELOG
gejohnston Jan 12, 2024
0c46f64
Add entry about profile removal to core CHANGELOG
gejohnston Jan 12, 2024
7f05a98
Changes to use only 1 copy of exitOnFailure.sh
gejohnston Jan 12, 2024
5844542
Add more info to changelog entries
gejohnston Jan 12, 2024
a4ffd89
Use baseCertKey variable, not hard-coded file name
gejohnston Jan 18, 2024
b687cb8
Switch order of tests for stderr and stdout
gejohnston Jan 18, 2024
5cb10f5
Merge remote-tracking branch 'origin/next' into no-v1-profiles
gejohnston Jan 19, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,45 +1,5 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`Imperative Secure Tests Cli Profile Manager Default Credential Management Generic Failure Scenarios should fail if the Credential Manager is unable to retrieve a password 1`] = `
"Command Preparation Failed:
Unable to load the secure field \\"username\\" associated with the profile \\"profile-name-changed\\" of type \\"username-password\\".
Error Details:
Unable to load credentials.
Could not find an entry in the credential vault for the following:
Service = example_with_profiles
Account = username-password_profile-name-changed_username

Possible Causes:
This could have been caused by any manual removal of credentials from your vault.

Resolutions:
Recreate the credentials in the vault for the particular service in the vault.
To recreate credentials, issue a 'profiles create' sub-command with the --ow flag.

"
`;

exports[`Imperative Secure Tests Cli Profile Manager Default Credential Management Generic Failure Scenarios should fail if the Credential Manager is unable to retrieve a password 2`] = `
"Your default profile named profile-name of type username-password was successfully deleted.
Because you deleted it, the default profile for type username-password has been cleared.
To set a new default profile, run \\"zowe profiles set-default username-password <profileName>\\".
"
`;

exports[`Imperative Secure Tests Cli Profile Manager Default Credential Management Generic Success Scenarios should update a password 1`] = `
"
Warning: The command 'profiles update' is deprecated.
Recommended replacement: The 'config set' command
"
`;

exports[`Imperative Secure Tests Cli Profile Manager Default Credential Management Generic Success Scenarios should update a password 2`] = `
"Your default profile named profile-name of type username-password was successfully deleted.
Because you deleted it, the default profile for type username-password has been cleared.
To set a new default profile, run \\"zowe profiles set-default username-password <profileName>\\".
"
`;

exports[`Imperative Secure Tests imperative-test-cli config profiles should list profiles 1`] = `
"secured
base
Expand Down
164 changes: 0 additions & 164 deletions __tests__/__integration__/imperative.integration.subtest.ts

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
/* eslint-disable max-len */

describe("Imperative Secure Tests", () => {
require("./imperative.integration.subtest");
require("./../../packages/imperative/__tests__/src/packages/profiles/__integration__/CliProfileManager.credentials.integration.subtest");
require("./../../packages/imperative/__tests__/src/packages/imperative/__integration__/PluginManagementFacility.integration.subtest");
require("./../../packages/imperative/__tests__/__integration__/imperative/__tests__/__integration__/cli/config/init/cli.imperative-test-cli.config.init.integration.subtest");
Expand All @@ -23,7 +22,6 @@ describe("Imperative Secure Tests", () => {
require("./../../packages/imperative/__tests__/__integration__/imperative/__tests__/__integration__/cli/config/profiles/cli.imperative-test-cli.config.profiles.integration.subtest");
require("./../../packages/imperative/__tests__/__integration__/imperative/__tests__/__integration__/cli/config/secure/cli.imperative-test-cli.config.secure.integration.subtest");
require("./../../packages/imperative/__tests__/__integration__/imperative/__tests__/__integration__/cli/config/set/cli.imperative-test-cli.config.set.integration.subtest");
require("./../../packages/imperative/__tests__/__integration__/imperative/__tests__/__integration__/cli/profiles/cli.imperative-test-cli.profiles.create.secured-profile.integration.subtest");
require("./../../packages/imperative/__tests__/__integration__/imperative/__tests__/__integration__/cli/test/cli.imperative-test-cli.test.config-auto-store.integration.subtest");
require("./../../packages/imperative/__tests__/__integration__/imperative/__tests__/__integration__/cli/test/cli.imperative-test-cli.test.config-override.integration.subtest");
});
Expand Down
12 changes: 12 additions & 0 deletions __tests__/__scripts__/exitOnFailure.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/sh

# function to exit if we encounter a bad return code
exitOnFailure () {
failureMsg=${1:?"First parm (failureMsg) is required."}
actualExitCode=${2:?"Second parm (actualExitCode) is required."}
goodExitCode=${3:-0}
if [ $actualExitCode != $goodExitCode ]; then
echo `basename $0`": $failureMsg" 1>&2
exit $actualExitCode
fi
}
3 changes: 2 additions & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ const sharedConfig = {
"testRegex": "__tests__.*\\.(spec|test)\\.ts$",
"moduleFileExtensions": [
"ts",
"js"
"js",
"json"
],
"testEnvironment": "node",
"testPathIgnorePatterns": [
Expand Down
Loading
Loading