Skip to content

Commit 9971b23

Browse files
authored
Update push.spec.ts
1 parent 066b228 commit 9971b23

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

simple-git/test/unit/push.spec.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,19 @@ describe('push', () => {
103103
return aPushedBranch(local, remote, state, false);
104104
}
105105

106+
it('will not match ill-formed push lines', () => {
107+
givenTheResponse({
108+
stdOut: [
109+
'* refs/tags/tag-one:refs/tags/tag-one [up to date]',
110+
'2 refs/tags/tag-one:refs/tags/tag-one [up to date]',
111+
'= refs/tags/tag-one:refs/tags/tag-one [up to date]',
112+
].join('\n'),
113+
stdErr: '',
114+
});
115+
116+
expect(actual.pushed).toHaveLength(2);
117+
});
118+
106119
it('parses pushing tags as well as branches', () => {
107120
givenTheResponse(pushNewBranchWithTags);
108121
expect(actual).toEqual(

0 commit comments

Comments
 (0)