diff options
-rw-r--r-- | testing/01-basics.yarn | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/testing/01-basics.yarn b/testing/01-basics.yarn index 00d8623..18f2e4f 100644 --- a/testing/01-basics.yarn +++ b/testing/01-basics.yarn @@ -79,3 +79,28 @@ when the new user runs 'ls' it doesn't get to see `gitano-admin` but that the WHEN testinstance adminkey runs ls THEN stdout contains RW gitano-admin +Basic repository creation +------------------------- + +In a default configuration, the only user who will be able to create +repositories. However creation can hand off ownership which means that we can +test that a new user who has a repository created for them can see it in ls. + + SCENARIO delegated repository creation works + + GIVEN a standard instance + AND a unix user called alice + AND alice has keys called main + WHEN testinstance, using adminkey, adds user alice, using alice main + AND testinstance adminkey runs create somerepo alice + AND alice main runs ls + THEN stdout contains RW somerepo + +And just to check, if the `testinstance` user created a non-delegated repo then +the `alice` user cannot see it. + + WHEN testinstance adminkey runs create anotherrepo + AND testinstance adminkey runs ls + THEN stdout contains RW anotherrepo + WHEN alice main runs ls + THEN stdout does not contain anotherrepo |