refactored source tests

This commit is contained in:
albert
2011-09-29 12:28:17 -04:00
parent 57a0a1e7bc
commit f188c6d70d
4 changed files with 46 additions and 4 deletions

View File

@@ -10,8 +10,19 @@ module Sources
@site.get
end
should "get a single post" do
should "get the profile" do
assert_equal("http://seiga.nicovideo.jp/user/illust/20446930?target=seiga", @site.profile_url)
end
should "get the artist name" do
assert_equal("rariemonn", @site.artist_name)
end
should "get the image url" do
assert_equal("http://seiga.nicovideo.jp/image/source?id=1464351", @site.image_url)
end
should "get the tags" do
assert(@site.tags.size > 0)
first_tag = @site.tags.first
assert_equal(2, first_tag.size)