guardian / gu-who

answering: who are all these users in my GitHub org?
https://gu-who.herokuapp.com/
Apache License 2.0
225 stars 56 forks source link

add a test mode #50

Open afeld opened 9 years ago

afeld commented 9 years ago

We are planning to use this @18F, and even though we've done some testing in a sandbox organization, it would be nice to see what the bot would do against our real org. Would be great to have a test/no-op option, where it (for example) prints out all of the issues it would file and the users it would kick out, without actually doing so. I've never done any Scala, but could possibly hack on this a bit if there's interest.

/cc @jgrevich

rtyley commented 9 years ago

You probably want an endpoint that'll print out the results of OrgUserProblems.problems and StateUpdate (which is one of MemberUserUpdate, MembershipTermination, or UserHasLeftOrg):

https://github.com/guardian/gu-who/blob/b5307f/app/lib/OrgUserProblems.scala#L80-L113 https://github.com/guardian/gu-who/blob/b5307f/app/lib/StateUpdate.scala#L24-L51

afeld commented 9 years ago

That would work!