Skip to content

Commit

Permalink
lifecycle: emit progress for packing (#52)
Browse files Browse the repository at this point in the history
Signed-off-by: Sergio Schvezov <sergio.schvezov@canonical.com>
  • Loading branch information
sergiusens authored Aug 22, 2023
1 parent 2e03268 commit a613d53
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions craft_application/commands/lifecycle.py
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,7 @@ def run(
raise RuntimeError(f"Step name {step_name} passed to pack command.")
super().run(parsed_args, step_name="prime")

emit.progress("Packing...")
packages = self._services.package.pack(parsed_args.output)

if not packages:
Expand Down
1 change: 1 addition & 0 deletions tests/unit/commands/test_lifecycle.py
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,7 @@ def test_pack_run(
command.run(parsed_args)

mock_services.package.pack.assert_called_once_with(tmp_path)
emitter.assert_progress("Packing...")
emitter.assert_message(message)


Expand Down

0 comments on commit a613d53

Please sign in to comment.