Skip to content

Commit e0eee1c

Browse files
committed
Adding test for Get-GitHubRepositoryBranch
1 parent 21cbd76 commit e0eee1c

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

Tests/GitHubAnalytics.tests.ps1

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -218,3 +218,14 @@ Describe 'Getting repository owner from url' {
218218
$owner | Should be "KarolKaczmarek"
219219
}
220220
}
221+
222+
Describe 'Getting branches for repository' {
223+
$branches = Get-GitHubRepositoryBranch -owner $script:organizationName -repository $script:repositoryName
224+
225+
It 'Should return expected number of repository branches' {
226+
@($branches).Count | Should be 1
227+
}
228+
It 'Should return the name of the branches' {
229+
@($branches[0].name) | Should be "master"
230+
}
231+
}

0 commit comments

Comments
 (0)