Permalink
Browse files

Merge branch 'master' of github.com:winton/gitcycle

Conflicts:
	README.md
  • Loading branch information...
tongueroo committed Mar 6, 2012
2 parents 7802143 + 82c2e15 commit 8897e0a6c2836d95609fda2f947019a1563fc3ce
View
@@ -2,7 +2,7 @@
*.gem
.bundle
coverage
-features/config.yml
+features/config/config.yml
features/fixtures
Gemfile.lock
pkg
View
@@ -35,6 +35,11 @@ Type `gitc branch` + your ticket URL to create a new branch:
gitc branch https://xxx.lighthouseapp.com/projects/0000/tickets/0000-my-ticket
+To collaborate with another user, use a full path when prompted:
+
+ Q: What branch would you like to eventually merge into?
+ A: user/branch
+
Pull
----
@@ -116,6 +121,13 @@ Label the issue with "Fail" and regenerate the QA branch without the failing iss
Label all issues "Pass" and the merge the QA branch into target branch.
+### Immediate Pass
+
+ gitc checkout [TARGET BRANCH]
+ gitc qa pass [GITHUB ISSUE #] [...]
+
+Immediately merge issue into the target branch.
+
### Status
See who is QA'ing what:
@@ -125,12 +137,6 @@ See who is QA'ing what:
Checkout
--------
-### Collaborate
-
-Checkout branches from other forks:
-
- gitc checkout [USER] [BRANCH]
-
### From Ticket
Checkout a branch from a ticket URL:
@@ -150,7 +156,6 @@ Todo
* gitc qa pass [issue] should use a qa_rc_tongueroo_temp branch so it doesnt blow away the changes in the qa_rc_tongueroo branch
* gitc qa pass (all), doesnt update lighthouse to state pending-approval
* Add comment on lighthouse with issue URL
-* Allow QA branches to be created from any branch and allow any issue to merge into it
* Collab fork should change gitc ready to auo merge to the parent fork. gitc pull should pull from br and parent fork. gitc push should push to your same fork.
Lighthouse ticket changes to pending-qa if ticket is not the same as the parent.
* gitc pull is not merging in br/rc
@@ -171,9 +176,8 @@ $ gitc st - shortcut
* There's still a Tagging Issue I tried to fix parseLabel http://d.pr/8eOS , Pass should remove Pending, but remove the Branch Name
* gitc qa pass 1234 # doesnt update lighthouse and screws up git issue tags
* [issue number] it marks it pending-qa and failed.. not correct. I'll take a look at this over the weekend -Tung
-* gitc qa pass # since we're changing this to pass all the tickets, we need to loop through all the merged issues and update the lighthouse state to pending-qa
-* gitc qa resolved is not working, we need gitc qa pass to merge the whole branch into the target branch
* gitc qa clean # to clean up old branches
* gitc qa pass # if ticket resolved, it should stay resolved
* gitc ready # if pull requests already created, it should prompt and explain that a new branch and issue is being created, consider effect of multiple developers
* fail should change to inactive
+* If feature branch changed between QA branch creation and QA merge, alert QA engineer
View
@@ -0,0 +1,96 @@
+Feature: Branch
+
+Scenario: Yes to all (easiest route)
+ Given a fresh set of repositories
+ When I cd to the user repo
+ And I execute gitcycle branch with a new URL or string
+ And I give default input
+ And gitcycle runs
+ Then output includes
+ """
+ Your work will eventually merge into 'master'. Is this correct? (y/n)
+ Retrieving branch information from gitcycle.
+ Would you like to name your branch 'master-ticket.id'? (y/n)
+ Adding remote repo 'config.owner/config.repo'.
+ Fetching remote 'config.owner'.
+ Checking out remote branch 'master-ticket.id' from 'config.owner/config.repo/master'.
+ Fetching remote 'origin'.
+ Pushing 'origin/master-ticket.id'.
+ Sending branch information to gitcycle.
+ """
+ And redis entries valid
+
+Scenario: Custom branch name
+ Given a fresh set of repositories
+ When I cd to the user repo
+ And I execute gitcycle branch with a new URL or string
+ And I enter "y"
+ And I enter "n"
+ And I enter "master-ticket.id-rename"
+ And gitcycle runs
+ Then output includes
+ """
+ Your work will eventually merge into 'master'. Is this correct? (y/n)
+ Retrieving branch information from gitcycle.
+ Would you like to name your branch 'master-ticket.id'? (y/n)
+ What would you like to name your branch?
+ Adding remote repo 'config.owner/config.repo'.
+ Fetching remote 'config.owner'.
+ Checking out remote branch 'master-ticket.id-rename' from 'config.owner/config.repo/master'.
+ Fetching remote 'origin'.
+ Pushing 'origin/master-ticket.id-rename'.
+ Sending branch information to gitcycle.
+ """
+ And redis entries valid
+
+Scenario: Change source branch
+ Given a fresh set of repositories
+ When I cd to the user repo
+ And I create a new branch "some_branch"
+ And I checkout some_branch
+ And I execute gitcycle branch with a new URL or string
+ And I enter "n"
+ And I enter "master"
+ And I enter "y"
+ And gitcycle runs
+ Then output includes
+ """
+ Your work will eventually merge into 'some_branch'. Is this correct? (y/n)
+ What branch would you like to eventually merge into?
+ Retrieving branch information from gitcycle.
+ Would you like to name your branch 'master-ticket.id'? (y/n)
+ Adding remote repo 'config.owner/config.repo'.
+ Fetching remote 'config.owner'.
+ Checking out remote branch 'master-ticket.id' from 'config.owner/config.repo/master'.
+ Fetching remote 'origin'.
+ Pushing 'origin/master-ticket.id'.
+ Sending branch information to gitcycle.
+ """
+ And redis entries valid
+
+Scenario: Collaborator
+ Given a fresh set of repositories
+ When I cd to the owner repo
+ And I create a new branch "some_branch"
+ And I checkout some_branch
+ And I push some_branch
+ And I cd to the user repo
+ And I execute gitcycle branch with a new URL or string
+ And I enter "n"
+ And I enter "config.owner/some_branch"
+ And I enter "y"
+ And gitcycle runs
+ Then output includes
+ """
+ Your work will eventually merge into 'master'. Is this correct? (y/n)
+ What branch would you like to eventually merge into?
+ Retrieving branch information from gitcycle.
+ Would you like to name your branch 'config.owner-some_branch-ticket.id'? (y/n)
+ Adding remote repo 'config.owner/config.repo'.
+ Fetching remote 'config.owner'.
+ Checking out remote branch 'config.owner-some_branch-ticket.id' from 'config.owner/config.repo/some_branch'.
+ Fetching remote 'origin'.
+ Pushing 'origin/config.owner-some_branch-ticket.id'.
+ Sending branch information to gitcycle.
+ """
+ And redis entries valid
View
@@ -0,0 +1,27 @@
+Feature: Checkout
+
+Scenario: Existing branch
+ Given a fresh set of repositories
+ When I cd to the user repo
+ And I execute gitcycle branch with a new URL or string
+ And I give default input
+ And I execute gitcycle checkout with the last URL or string
+ And gitcycle runs
+ Then output includes
+ """
+ Retrieving branch information from gitcycle.
+ Checking out branch 'master-ticket.id'.
+ """
+ And current branch is "master-ticket.id"
+
+Scenario: Fresh repo
+ Given a fresh set of repositories
+ When I cd to the user repo
+ And I execute gitcycle checkout with the last URL or string
+ And gitcycle runs
+ Then output includes
+ """
+ Retrieving branch information from gitcycle.
+ Tracking branch 'origin/master-last_ticket.id'.
+ """
+ And current branch is "master-last_ticket.id"
File renamed without changes.
View
@@ -0,0 +1,46 @@
+Feature: Discuss
+
+Scenario: No parameters and nothing committed
+ Given a fresh set of repositories
+ When I cd to the user repo
+ And I execute gitcycle branch with a new URL or string
+ And I give default input
+ And I execute gitcycle with "discuss"
+ And gitcycle runs
+ Then output includes
+ """
+ Retrieving branch information from gitcycle.
+ Creating GitHub pull request.
+ You must push code before opening a pull request.
+ """
+ And redis entries valid
+
+Scenario: No parameters and something committed
+ Given a fresh set of repositories
+ When I cd to the user repo
+ And I execute gitcycle branch with a new URL or string
+ And I give default input
+ And gitcycle runs
+ And I commit something
+ And I execute gitcycle with "discuss"
+ And gitcycle runs
+ Then output includes
+ """
+ Retrieving branch information from gitcycle.
+ Creating GitHub pull request.
+ Labeling issue as 'Discuss'.
+ """
+ And output includes "Opening issue" with URL
+ And URL is a valid issue
+ And redis entries valid
+
+Scenario: Parameters
+ When I cd to the user repo
+ And I execute gitcycle with "discuss issue.id"
+ And gitcycle runs
+ Then output includes "Retrieving branch information from gitcycle."
+ And output does not include "Creating GitHub pull request."
+ And output does not include "Branch not found."
+ And output does not include "You must push code before opening a pull request."
+ And output includes "Opening issue" with URL
+ And URL is a valid issue
View
@@ -0,0 +1,11 @@
+Feature: Errors
+
+Scenario: No command given
+ When I execute gitcycle with nothing
+ And gitcycle runs
+ Then output includes "No command specified"
+
+Scenario: Non-existent command
+ When I execute gitcycle with "blah blah"
+ And gitcycle runs
+ Then output includes "Command not recognized."
Oops, something went wrong.

0 comments on commit 8897e0a

Please sign in to comment.