Skip to content

Commit

Permalink
Add a spec of StoreTargetLink #30
Browse files Browse the repository at this point in the history
  • Loading branch information
kzgs committed Mar 4, 2012
1 parent 949b910 commit 2cd470e
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions spec/plugins/store/target_link_spec.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# -*- coding: utf-8 -*-
# Name:: Automatic::Plugin::CustomFeed::SVNFLog
# Author:: kzgs
# Created:: Mar 4, 2012
# Updated:: Mar 4, 2012
# Copyright:: kzgs Copyright (c) 2012
# License:: Licensed under the GNU GENERAL PUBLIC LICENSE, Version 3.0.

require File.expand_path(File.dirname(__FILE__) + '../../../spec_helper')

require 'store/target_link'

require 'tmpdir'
require 'pathname'

describe Automatic::Plugin::StoreTargetLink do
it "should store the target link" do
Dir.mktmpdir do |dir|
instance = Automatic::Plugin::StoreTargetLink.new(
{ "path" => dir },
AutomaticSpec.generate_pipeline {
feed { item "http://digithoughts.com/rss" }
})

instance.run.should have(1).feed
(Pathname(dir)+"rss").should be_exist
end
end
end

0 comments on commit 2cd470e

Please sign in to comment.