Properly stop the repo and revwalk servers

Return the 4-tuple when asked to stop instead of the 3-tuple so we do
indicate the stop was normal.
This commit is contained in:
Carlos Martín Nieto
2013-04-10 20:11:07 +02:00
parent d0034b1142
commit 353995a2da
4 changed files with 16 additions and 8 deletions

View File

@@ -22,5 +22,5 @@ odb_write_test(Repo) ->
Expected = geef_oid:parse("c300118399f01fe52b316061b5d32beb27e0adfd"),
[?_assertEqual(Actual, Expected)].
stop(_Repo) ->
ok.
stop(Repo) ->
geef_repo:stop(Repo).

View File

@@ -28,7 +28,9 @@ amount_test(Repo) ->
{ok, Walk} = geef_repo:revwalk(Repo),
Id = geef_oid:parse("a4a7dce85cf63874e984719f4fdd239f5145052f"),
ok = geef_revwalk:push(Walk, Id),
[?_assertEqual(6, count_walk(Walk, 0))].
Count = count_walk(Walk, 0),
geef_revwalk:stop(Walk),
[?_assertEqual(6, Count)].
stop(_Repo) ->
ok.
stop(Repo) ->
geef_repo:stop(Repo).