Sha256: 3151d5d832f2f24090bb76f64c17aa65b54c6d2e87fc87446c128d98196cae61
Contents?: true
Size: 1.29 KB
Versions: 2
Compression:
Stored size: 1.29 KB
Contents
require File.expand_path(File.dirname(__FILE__) + '/spec_helper') describe TaskMapper::Provider::Bugzilla::Comment do before(:all) do @klass = TaskMapper::Provider::Bugzilla::Comment end before(:each) do VCR.use_cassette('init-tm-for-comments') { @taskmapper = TaskMapper.new(:bugzilla, {:username => 'george.rafael@gmail.com', :password => '123456', :url => 'https://landfill.bugzilla.org/bugzilla-3.6-branch'}) } VCR.use_cassette('project-for-comment') { @project = @taskmapper.project(20) } VCR.use_cassette('ticket-for-comment') { @ticket = @project.ticket(7039) } end it "should be able to load all comments from a ticket" do VCR.use_cassette('comments-all') { @comments = @ticket.comments } @comments.should be_an_instance_of(Array) @comments.first.should be_an_instance_of(@klass) end it "should be able to load all comments based on array of id's" do VCR.use_cassette('comments-by-array') { @comments = @ticket.comments([18575]) } @comments.should be_an_instance_of(Array) @comments.first.should be_an_instance_of(@klass) end it "should be able to load a comment based on an id" do VCR.use_cassette('comments-by-id') { @comment = @ticket.comment(18575) } @comment.should be_an_instance_of(@klass) @comment.id.should == 18575 end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
taskmapper-bugzilla-0.4.0 | spec/comments_spec.rb |
taskmapper-bugzilla-0.3.0 | spec/comments_spec.rb |