diff options
| author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-10-28 19:19:41 +0200 |
|---|---|---|
| committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-10-28 19:19:41 +0200 |
| commit | 8f9c11af3c14c0036e7038c33262367288a09ac8 (patch) | |
| tree | ea2eb2fd069ee750d6131b043c0623384307032e /spec | |
| parent | 823aba63e444afa2f45477819770fec3cb5f0159 (diff) | |
| parent | 6cd167eaac7b764bcaefe31a9144dd38992cc9ab (diff) | |
| download | gitlab-shell-8f9c11af3c14c0036e7038c33262367288a09ac8.tar.gz | |
Merge pull request #179 from feedhenry/projects_list
Added list-projects command & spec
Diffstat (limited to 'spec')
| -rw-r--r-- | spec/gitlab_projects_spec.rb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/spec/gitlab_projects_spec.rb b/spec/gitlab_projects_spec.rb index 0060fa9..a592e62 100644 --- a/spec/gitlab_projects_spec.rb +++ b/spec/gitlab_projects_spec.rb @@ -135,6 +135,22 @@ describe GitlabProjects do end end + describe :list_projects do + let(:gl_projects) do + build_gitlab_projects('add-project', "list_test/#{repo_name}") + end + + before do + FileUtils.mkdir_p(tmp_repos_path) + end + + it 'should create projects and list them' do + GitlabProjects.stub(create_hooks: true) + gl_projects.exec + gl_projects.send(:list_projects).should == ["list_test/#{repo_name}"] + end + end + describe :mv_project do let(:gl_projects) { build_gitlab_projects('mv-project', repo_name, 'repo.git') } let(:new_repo_path) { File.join(tmp_repos_path, 'repo.git') } |
