diff --git a/Gemfile b/Gemfile index 812449db..ed3cdc44 100644 --- a/Gemfile +++ b/Gemfile @@ -1,4 +1,3 @@ source "http://rubygems.org" -ruby RUBY_VERSION # Specify your gem's dependencies in cloudinary.gemspec gemspec diff --git a/spec/cloudinary_spec.rb b/spec/cloudinary_spec.rb index c582c158..e318b7ba 100644 --- a/spec/cloudinary_spec.rb +++ b/spec/cloudinary_spec.rb @@ -9,8 +9,8 @@ Cloudinary.user_platform = @user_platform end - CLOUDINARY_USER_AGENT_REGEXP = %r"^CloudinaryRuby\/[\d.]+ \(Ruby [\d\.]+-p\d+\)$" - CLOUDINARY_USER_PLATFORM_REGEXP = %r"^Rails\/[\d.]+ CloudinaryRuby\/[\d.]+ \(Ruby [\d\.]+-p\d+\)$" + CLOUDINARY_USER_AGENT_REGEXP = %r"^CloudinaryRuby\/[\d.]+ \(Ruby [\d\.]+-p-?\d+\)$" + CLOUDINARY_USER_PLATFORM_REGEXP = %r"^Rails\/[\d.]+ CloudinaryRuby\/[\d.]+ \(Ruby [\d\.]+-p-?\d+\)$" it "should return the USER_AGENT without user_platform if there's no Rails or set to empty" do Cloudinary.user_platform = ""