listStatuses method
Lists the statuses of a repository at the specified reference.
The ref
can be a SHA, a branch name, or a tag name.
API docs: https://developer.github.com/v3/repos/statuses/#list-statuses-for-a-specific-ref
Implementation
Stream<RepositoryStatus> listStatuses(RepositorySlug slug, String ref) {
ArgumentError.checkNotNull(slug);
ArgumentError.checkNotNull(ref);
return PaginationHelper(github)
.objects<Map<String, dynamic>, RepositoryStatus>(
'GET',
'/repos/${slug.fullName}/commits/$ref/statuses',
RepositoryStatus.fromJson,
);
}