Sha256: b31f86a6bf9fd3ffe5b093a3f027d137029031827586bbb44954f2cc3d84d830
Contents?: true
Size: 796 Bytes
Versions: 3
Compression:
Stored size: 796 Bytes
Contents
# encoding: utf-8 require 'spec_helper' describe GithubCLI::Commands::Commits do let(:format) { {'format' => 'table'} } let(:user) { 'peter-murach' } let(:repo) { 'github_cli' } let(:sha) { '3a0f86fb8db8eea7ccbb9a95f325ddbedfb25e15' } let(:api_class) { GithubCLI::Commit } it "invokes commit:get" do api_class.should_receive(:get).with(user, repo, sha, {}, format) subject.invoke "commit:get", [user, repo, sha] end it "invokes commit:create" do api_class.should_receive(:create).with(user, repo, {}, format) subject.invoke "commit:create", [user, repo] end it "invokes commit:create --tree" do api_class.should_receive(:create).with(user, repo, {"tree" => sha}, format) subject.invoke "commit:create", [user, repo], :tree => sha end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
github_cli-0.6.2 | spec/github_cli/commands/commits_spec.rb |
github_cli-0.6.1 | spec/github_cli/commands/commits_spec.rb |
github_cli-0.6.0 | spec/github_cli/commands/commits_spec.rb |