Skip to content

Commit

Permalink
Merge pull request #696 from steveukx/fix/empty-commits
Browse files Browse the repository at this point in the history
fix: Add example for empty commit message in `git.commit()`
  • Loading branch information
steveukx committed Dec 1, 2021
2 parents 080c82b + 61089cb commit 617b87e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions test/unit/commit.spec.ts
Expand Up @@ -21,6 +21,12 @@ describe('commit', () => {
});

describe('usage', () => {
it('empty commit', async () => {
git.commit([], {'--amend': null, '--no-edit': null});
await closeWithSuccess();
assertExecutedCommands('commit', '--amend', '--no-edit');
});

it('single message, no files, no options and callback', async () => {
const task = git.commit('message', callback);
await closeWithSuccess();
Expand Down

0 comments on commit 617b87e

Please sign in to comment.