diff options
author | HampusM <hampus@hampusmat.com> | 2021-08-11 12:59:23 +0200 |
---|---|---|
committer | HampusM <hampus@hampusmat.com> | 2021-08-11 12:59:23 +0200 |
commit | 108b469cbb09f911c9a52d4134a504d9b51ac30d (patch) | |
tree | 309763642bf53b4adecf20bfd09047715f572c39 /test/util.ts | |
parent | 3eb8757b8db81476782870d460e3d856907186a7 (diff) |
Implemented gpg signed commit support
Diffstat (limited to 'test/util.ts')
-rw-r--r-- | test/util.ts | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/test/util.ts b/test/util.ts index 5886514..0079580 100644 --- a/test/util.ts +++ b/test/util.ts @@ -1,4 +1,4 @@ -import { Commit } from "server/src/git/commit"; +import { Commit, CommitAuthor } from "server/src/git/commit"; export type EnvironmentVariables = { BASE_DIR: string, @@ -14,8 +14,11 @@ export type EnvironmentVariables = { export function expectCommitProperties(commit: Commit): void { expect(commit).toHaveProperty("id"); expect(commit).toHaveProperty("author"); - expect(commit).toHaveProperty("author.name"); - expect(commit).toHaveProperty("author.email"); + + const author = commit.author(); + expect(author).toBeInstanceOf(CommitAuthor); + expect(commit).toHaveProperty("date"); expect(commit).toHaveProperty("message"); + expect(commit).toHaveProperty("isSigned"); }
\ No newline at end of file |