RFR: Add Host::isMemberOf
Robin Westberg
rwestberg at openjdk.org
Wed Oct 2 06:53:01 UTC 2019
On Tue, 1 Oct 2019 14:56:45 GMT, Erik Helin <ehelin at openjdk.org> wrote:
> Hi all,
>
> this patch adds a new method `Host::isMemberOf` that can be used to query a host (e.g. GitHub or Gitlab) if a specific user is a member of a particular group. I couldn't come up with a positive test for the method, since it is really hard to rely on a test user being a member of a particular group, but I could at least write a negative test.
>
> ## Testing
> - [x] `sh gradlew test` passes on Linux x86_64
>
> Thanks,
> Erik
>
> ----------------
>
> Commits:
> - 52633d26: Add Host::isMemberOf
>
> Changes: https://git.openjdk.java.net/skara/pull/173/files
> Webrev: https://webrevs.openjdk.java.net/skara/173/webrev.00
> Stats: 70 lines in 5 files changed: 70 ins; 0 del; 0 mod
> Patch: https://git.openjdk.java.net/skara/pull/173.diff
> Fetch: git fetch https://git.openjdk.java.net/skara pull/173/head:pull/173
host/src/main/java/org/openjdk/skara/host/Host.java line 34:
> 33: boolean supportsReviewBody();
> 34: boolean isMemberOf(long groupId, HostUserDetails user);
> 35:
You may want to make the groupId parameter a String instead, there are hosts out there that we may want to support that don't use numerical ids.
PR: https://git.openjdk.java.net/skara/pull/173
More information about the skara-dev
mailing list