Skip to content

Commit 255e0ed

Browse files
Ensure author identity
1 parent b9175ec commit 255e0ed

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

tests/Gitonomy/Git/Tests/LogTest.php

+5
Original file line numberDiff line numberDiff line change
@@ -80,9 +80,14 @@ public function testIterable($repository)
8080
public function testFirstMessageEmpty()
8181
{
8282
$repository = $this->createEmptyRepository(false);
83+
$repository->run('config', ['--local', 'user.name', '"Unit Test"']);
84+
$repository->run('config', ['--local', 'user.email', '"[email protected]"']);
85+
86+
// Edge case: first commit lacks a message.
8387
file_put_contents($repository->getWorkingDir().'/file', 'foo');
8488
$repository->run('add', ['.']);
8589
$repository->run('commit', ['--allow-empty-message', '--no-edit']);
90+
8691
$commits = $repository->getLog()->getCommits();
8792
$this->assertCount(1, $commits);
8893
}

0 commit comments

Comments
 (0)