spec/localeapp/routes_spec.rb in localeapp-1.0.2 vs spec/localeapp/routes_spec.rb in localeapp-2.0.0
- old
+ new
@@ -96,9 +96,15 @@
it "it extends the project_url and includes the escaped key name" do
with_configuration(@config) do
expect(@routes.remove_url(:key => 'test.key')).to eq("https://test.host/v1/projects/API_KEY/translations/test%2Ekey")
end
end
+
+ it "URL encodes the key name" do
+ with_configuration @config do
+ expect(@routes.remove_url key: "some key").to include "some+key"
+ end
+ end
end
describe "#rename_endpoint(options = {})" do
it "returns :post and the rename url for the options" do
with_configuration(@config) do