When starting an anonymous transaction then a GitDbTransaction is returned
This commit is contained in:
parent
57e39d71ad
commit
bd4306bbc0
1 changed files with 12 additions and 0 deletions
|
@ -326,6 +326,18 @@ class GitDBTest implements WithAssertions {
|
|||
}
|
||||
|
||||
// When starting an anonymous transaction then a GitDbTransaction is returned
|
||||
@Test
|
||||
void startAnonymousTransaction_thenReturnGitDBTransaction() throws IOException {
|
||||
//given
|
||||
final String key = stringSupplier.get();
|
||||
final String value = stringSupplier.get();
|
||||
final GitDBBranch gitDBBranch = gitDBBranchWithKeyValue(key, value);
|
||||
//when
|
||||
final GitDBTransaction transaction = gitDBBranch.transaction();
|
||||
//then
|
||||
assertThat(transaction).isNotNull();
|
||||
assertThat(transaction.name()).isNotNull();
|
||||
}
|
||||
|
||||
// Given a GitDbTransaction handle (i.e. a new branch)
|
||||
// When putting a new key/value pair then the original GitDbBranch can't find it
|
||||
|
|
Loading…
Reference in a new issue