mirror of
https://github.com/discourse/discourse.git
synced 2024-11-23 06:04:11 +08:00
parent
f506843074
commit
4d1204b5e8
|
@ -78,4 +78,15 @@ describe "S3Helper" do
|
|||
end
|
||||
end
|
||||
end
|
||||
|
||||
it "should prefix bucket folder path only if not exists" do
|
||||
s3_helper = S3Helper.new('bucket/folder_path')
|
||||
bucket = stub('s3_bucket')
|
||||
|
||||
s3_helper.expects(:s3_bucket).returns(bucket).twice
|
||||
bucket.expects(:object).with("folder_path/original/1X/def.xyz").twice
|
||||
|
||||
s3_helper.object("original/1X/def.xyz")
|
||||
s3_helper.object("folder_path/original/1X/def.xyz")
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue
Block a user