Skip to content

Commit

Permalink
refactor: convert capabilities:translations command to yargs
Browse files Browse the repository at this point in the history
  • Loading branch information
rossiam committed Jan 16, 2025
1 parent 3d1a1bd commit b7586b0
Show file tree
Hide file tree
Showing 17 changed files with 494 additions and 340 deletions.
111 changes: 0 additions & 111 deletions packages/cli/src/__tests__/commands/capabilities/translations.test.ts

This file was deleted.

190 changes: 0 additions & 190 deletions packages/cli/src/commands/capabilities/translations.ts

This file was deleted.

10 changes: 7 additions & 3 deletions src/__tests__/commands/capabilities/presentation.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ describe('handler', () => {

expect(apiOrganizationCommandMock).toHaveBeenCalledExactlyOnceWith(defaultInputArgv)
expect(chooseCapabilityMock)
.toHaveBeenCalledExactlyOnceWith(command, undefined, undefined, undefined, undefined, { allowIndex: true })
.toHaveBeenCalledExactlyOnceWith(command, undefined, undefined, { allowIndex: true })
expect(apiCapabilitiesGetPresentationMock).toHaveBeenCalledExactlyOnceWith('chosen-id', 3)
expect(formatAndWriteItemMock).toHaveBeenCalledExactlyOnceWith(
command,
Expand All @@ -139,7 +139,11 @@ describe('handler', () => {
namespace: 'namespace',
})).resolves.not.toThrow()

expect(chooseCapabilityMock)
.toHaveBeenCalledExactlyOnceWith(command, 'cmd-line-id', 13, undefined, 'namespace', { allowIndex: true })
expect(chooseCapabilityMock).toHaveBeenCalledExactlyOnceWith(
command,
'cmd-line-id',
13,
{ namespace: 'namespace', allowIndex: true },
)
})
})
Loading

0 comments on commit b7586b0

Please sign in to comment.