-
Notifications
You must be signed in to change notification settings - Fork 59
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
SNOW-1734018 SPCS command fixes #1710
Conversation
1a33126
to
c6e6447
Compare
1b6fdce
to
32b9966
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Please ensure the SPCS integration tests runs successfully before merging.
RELEASE-NOTES.md
Outdated
|
||
## Fixes and improvements | ||
* `snow spcs service set` now supports `--eai-name` to update external access integrations for a service. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This also looks like a new addition.
RELEASE-NOTES.md
Outdated
|
||
## Fixes and improvements | ||
* `snow spcs service set` now supports `--eai-name` to update external access integrations for a service. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably also mentioning that we improve the snow spcs service list-images
result by including enriched info like tag and sha
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point! I will update.
|
||
result = runner.invoke( | ||
["spcs", "image-repository", "list-images", "IMAGES", "--format", "JSON"] | ||
) | ||
|
||
assert result.exit_code == 0, result.output | ||
assert json.loads(result.output) == [{"image": "/DB/SCHEMA/IMAGES/super-cool-repo"}] | ||
assert "/db/schema/repo/echo_service" in result.output |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: why don't we assert cursor == result directly?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The output is in table format. I guess we could make it json and compare. But the return value is faked entirely. For example, it has the same effect as making cursor
return foo
and assert the result is the same as foo
.
|
||
mock_list_instances.assert_called_once_with(service_name=service_name) | ||
assert result.exit_code == 0 | ||
assert "TEST_SERVICE" in result.output, str(result.output) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: why don't we assert cursor == result directly?
32b9966
to
f3e36a5
Compare
0622a28
to
c7dfcb5
Compare
Integration test failed but doesn't look like related |
c7dfcb5
to
b480011
Compare
af8fb05
to
fed0ea1
Compare
Pre-review checklist
Changes description
SNOW-1734018
Updates the following
snow spcs
commands:Deprecations
snow spcs service status
andsnow spcs image-repository list-tags
.New additions
snow spcs service list-instances
,snow spcs service list-containers
andsnow spcs service list-roles
commands, which support fetching information about all instances/containers/service roles in a service.Fixes and improvements
snow spcs service set
now supports--eai-name
to update external access integrations for a service.snow spcs service list-images
now displays image tag and digest.