Skip to content

Commit

Permalink
🤡 Fix mock of write sheet service in update command tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Lukáš Horák committed Jan 13, 2022
1 parent 7c17834 commit e9f82fc
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions packages/cli/src/commands/__tests__/update.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -746,7 +746,11 @@ describe("update command", () => {

when(mockWrite)
.calledWith(
`/ROOT_PKG_PATH/${translationsDir}/sheet2-title.${languages[0]}.json`,
{
language: languages[0],
domain: "sheet2-title",
outputDir: `/ROOT_PKG_PATH/${translationsDir}`,
},
mockSheetLines2,
jsonTransformer
)
Expand All @@ -755,7 +759,11 @@ describe("update command", () => {
});
when(mockWrite)
.calledWith(
`/ROOT_PKG_PATH/${translationsDir}/sheet1-title.${languages[1]}.json`,
{
language: languages[1],
domain: "sheet1-title",
outputDir: `/ROOT_PKG_PATH/${translationsDir}`,
},
mockSheetLines,
jsonTransformer
)
Expand Down

0 comments on commit e9f82fc

Please sign in to comment.