Add anifty.jp support
This commit is contained in:
43
test/unit/sources/anifty_test.rb
Normal file
43
test/unit/sources/anifty_test.rb
Normal file
@@ -0,0 +1,43 @@
|
||||
require "test_helper"
|
||||
|
||||
module Sources
|
||||
class AniftyTest < ActiveSupport::TestCase
|
||||
strategy_should_work(
|
||||
"https://anifty.jp/ja/creations/1500",
|
||||
image_urls: ["https://storage.googleapis.com/anifty-media/creation/0x0913be22dd08f7e092e00d4f8c2f61778dc6df94/a5bb2c63b8a602aba6cfd93d2147bef23b6b9bc2.jpg"],
|
||||
profile_url: "https://anifty.jp/@inamihatoko",
|
||||
page_url: "https://anifty.jp/creations/1500",
|
||||
artist_name: "inami hatoko",
|
||||
other_names: ["inamihatoko", "井波ハトコ"],
|
||||
tags: ["background", "girl"],
|
||||
artist_commentary_title: "Escape",
|
||||
artist_commentary_desc: "Let's get out of there."
|
||||
)
|
||||
|
||||
strategy_should_work(
|
||||
"https://anifty.imgix.net/creation/0x9942a21fdc78fe2c3973d219a1d705a4efd056b4/22f4c9694dd2f1f32b610d1d75a18621c5c2d6d8.jpg?w=3840&q=undefined&auto=compress",
|
||||
image_urls: ["https://storage.googleapis.com/anifty-media/creation/0x9942a21fdc78fe2c3973d219a1d705a4efd056b4/22f4c9694dd2f1f32b610d1d75a18621c5c2d6d8.jpg"],
|
||||
profile_url: "https://anifty.jp/@unagi189",
|
||||
page_url: "https://anifty.jp/creations/1585",
|
||||
artist_name: "yunagi",
|
||||
other_names: ["unagi189", "夕凪"],
|
||||
tags: ["background", "girl", "uniform"],
|
||||
artist_commentary_title: "Sound!",
|
||||
artist_commentary_desc: "This work was created in 2017 and partially modified for exhibition.I created this work with the image of after-school for the girls in the brass band."
|
||||
)
|
||||
|
||||
strategy_should_work(
|
||||
"https://storage.googleapis.com/anifty-media/profile/0x961d09077b4a9f7a27f6b7ee78cb4c26f0e72c18/a6d2c366a3e876ddbf04fc269b63124be18af424.png",
|
||||
image_urls: ["https://storage.googleapis.com/anifty-media/profile/0x961d09077b4a9f7a27f6b7ee78cb4c26f0e72c18/a6d2c366a3e876ddbf04fc269b63124be18af424.png"],
|
||||
profile_url: "https://anifty.jp/@hightree",
|
||||
page_url: nil,
|
||||
artist_name: "Knoy Konome",
|
||||
other_names: ["hightree", "木芽のい"],
|
||||
tags: [],
|
||||
artist_commentary_title: nil,
|
||||
artist_commentary_desc: nil
|
||||
)
|
||||
|
||||
strategy_should_work("https://anifty.jp/zh/creations/373123123", deleted: true, profile_url: nil)
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user