Logo: Relish

  1. Sign up
  2. Sign in

Project: Gittyup

Combine git add, commit, and push into one command

As an aspiring web developer with little 'git' experience
I want to deploy my changes to Heroku with one command
So that everyone in the world can see them

Scenarios
Successfully add, commit, and (fake) push
Given
a git repository with pending changes
And
there is a git remote named heroku
When
I run adcopu interactively
And
I type "more golden retriever puppies"
Then
the output should contain "No such app"
And
the exit status should not be 0
The git repository does not exist
Given
a blank directory
When
I run adcopu
Then
the exit status should not be 0
And
the output should contain "Not a git repository"
No files changed (nothing to commit)
Given
an initialized git repository
When
I run adcopu
Then
the exit status should not be 0
And
the output should contain "No files have been changed"
Errors from git add

This scenario does not have any steps.

Cannot commit without commit message
Given
a git repository with pending changes
When
I run adcopu interactively
And
I type ""
Then
the output should contain "empty commit message"
And
the exit status should not be 0
Cannot push without a remote named 'heroku'
Given
a git repository with indexed changes
But
there is no remote named heroku
When
I run adcopu interactively
And
I type "railsbridge workshop changes"
Then
the exit status should not be 0
And
the output should contain "'heroku' does not appear"

Last published about 2 years ago by slothbear.