ajax_validator 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +8 -7
- data/app/models/ajax_validator/validator.rb +7 -2
- data/lib/ajax_validator/version.rb +1 -1
- data/spec/dummy/db/schema.rb +1 -1
- data/spec/dummy/log/development.log +626 -0
- data/spec/dummy/log/test.log +588 -0
- data/spec/dummy/tmp/capybara/screenshot.html +12 -0
- data/spec/dummy/tmp/capybara/screenshot.png +0 -0
- data/spec/features/ajax_validator/example_spec.rb +14 -0
- metadata +15 -25
- data/config/cucumber.yml +0 -8
- data/lib/tasks/cucumber.rake +0 -65
| @@ -0,0 +1,12 @@ | |
| 1 | 
            +
            <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0//EN"><html><head><title>Internal Server Error</title></head>
         | 
| 2 | 
            +
              <body>
         | 
| 3 | 
            +
                <h1>Internal Server Error</h1>
         | 
| 4 | 
            +
                No route matches [GET] "/base"
         | 
| 5 | 
            +
                <hr>
         | 
| 6 | 
            +
                <address>
         | 
| 7 | 
            +
                 WEBrick/1.3.1 (Ruby/2.2.4/2015-12-16) at
         | 
| 8 | 
            +
                 127.0.0.1:51997
         | 
| 9 | 
            +
                </address>
         | 
| 10 | 
            +
              
         | 
| 11 | 
            +
             | 
| 12 | 
            +
            </body></html>
         | 
| Binary file | 
| @@ -0,0 +1,14 @@ | |
| 1 | 
            +
            require "rails_helper"
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            RSpec.feature "Engine management", :type => :feature do
         | 
| 4 | 
            +
              scenario "User makes a request" do
         | 
| 5 | 
            +
                # TODO:
         | 
| 6 | 
            +
                #visit "/ajax_validator/validators"
         | 
| 7 | 
            +
             | 
| 8 | 
            +
                #fill_in "Name", :with => "My Widget"
         | 
| 9 | 
            +
                #click_button "Create Widget"
         | 
| 10 | 
            +
             | 
| 11 | 
            +
                #expect(page).to have_text("Widget was successfully created.")
         | 
| 12 | 
            +
                expect(true).to be(true)
         | 
| 13 | 
            +
              end
         | 
| 14 | 
            +
            end
         | 
    
        metadata
    CHANGED
    
    | @@ -1,14 +1,14 @@ | |
| 1 1 | 
             
            --- !ruby/object:Gem::Specification
         | 
| 2 2 | 
             
            name: ajax_validator
         | 
| 3 3 | 
             
            version: !ruby/object:Gem::Version
         | 
| 4 | 
            -
              version: 0.0. | 
| 4 | 
            +
              version: 0.0.3
         | 
| 5 5 | 
             
            platform: ruby
         | 
| 6 6 | 
             
            authors:
         | 
| 7 7 | 
             
            - Marcin Kalita
         | 
| 8 8 | 
             
            autorequire: 
         | 
| 9 9 | 
             
            bindir: exe
         | 
| 10 10 | 
             
            cert_chain: []
         | 
| 11 | 
            -
            date: 2016- | 
| 11 | 
            +
            date: 2016-07-26 00:00:00.000000000 Z
         | 
| 12 12 | 
             
            dependencies:
         | 
| 13 13 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 14 14 | 
             
              name: rake
         | 
| @@ -165,7 +165,7 @@ dependencies: | |
| 165 165 | 
             
                  - !ruby/object:Gem::Version
         | 
| 166 166 | 
             
                    version: '0'
         | 
| 167 167 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 168 | 
            -
              name:  | 
| 168 | 
            +
              name: database_cleaner
         | 
| 169 169 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| 170 170 | 
             
                requirements:
         | 
| 171 171 | 
             
                - - ">="
         | 
| @@ -179,21 +179,7 @@ dependencies: | |
| 179 179 | 
             
                  - !ruby/object:Gem::Version
         | 
| 180 180 | 
             
                    version: '0'
         | 
| 181 181 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 182 | 
            -
              name:  | 
| 183 | 
            -
              requirement: !ruby/object:Gem::Requirement
         | 
| 184 | 
            -
                requirements:
         | 
| 185 | 
            -
                - - ">="
         | 
| 186 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 187 | 
            -
                    version: 1.4.0
         | 
| 188 | 
            -
              type: :development
         | 
| 189 | 
            -
              prerelease: false
         | 
| 190 | 
            -
              version_requirements: !ruby/object:Gem::Requirement
         | 
| 191 | 
            -
                requirements:
         | 
| 192 | 
            -
                - - ">="
         | 
| 193 | 
            -
                  - !ruby/object:Gem::Version
         | 
| 194 | 
            -
                    version: 1.4.0
         | 
| 195 | 
            -
            - !ruby/object:Gem::Dependency
         | 
| 196 | 
            -
              name: database_cleaner
         | 
| 182 | 
            +
              name: formulaic
         | 
| 197 183 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| 198 184 | 
             
                requirements:
         | 
| 199 185 | 
             
                - - ">="
         | 
| @@ -207,7 +193,7 @@ dependencies: | |
| 207 193 | 
             
                  - !ruby/object:Gem::Version
         | 
| 208 194 | 
             
                    version: '0'
         | 
| 209 195 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 210 | 
            -
              name:  | 
| 196 | 
            +
              name: poltergeist
         | 
| 211 197 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| 212 198 | 
             
                requirements:
         | 
| 213 199 | 
             
                - - ">="
         | 
| @@ -221,7 +207,7 @@ dependencies: | |
| 221 207 | 
             
                  - !ruby/object:Gem::Version
         | 
| 222 208 | 
             
                    version: '0'
         | 
| 223 209 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 224 | 
            -
              name:  | 
| 210 | 
            +
              name: fuubar
         | 
| 225 211 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| 226 212 | 
             
                requirements:
         | 
| 227 213 | 
             
                - - ">="
         | 
| @@ -235,7 +221,7 @@ dependencies: | |
| 235 221 | 
             
                  - !ruby/object:Gem::Version
         | 
| 236 222 | 
             
                    version: '0'
         | 
| 237 223 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 238 | 
            -
              name:  | 
| 224 | 
            +
              name: capybara-puma
         | 
| 239 225 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| 240 226 | 
             
                requirements:
         | 
| 241 227 | 
             
                - - ">="
         | 
| @@ -249,7 +235,7 @@ dependencies: | |
| 249 235 | 
             
                  - !ruby/object:Gem::Version
         | 
| 250 236 | 
             
                    version: '0'
         | 
| 251 237 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 252 | 
            -
              name: capybara- | 
| 238 | 
            +
              name: capybara-screenshot
         | 
| 253 239 | 
             
              requirement: !ruby/object:Gem::Requirement
         | 
| 254 240 | 
             
                requirements:
         | 
| 255 241 | 
             
                - - ">="
         | 
| @@ -264,7 +250,7 @@ dependencies: | |
| 264 250 | 
             
                    version: '0'
         | 
| 265 251 | 
             
            description: Ajax Validator is a Rails engine that allows to validate form fields.
         | 
| 266 252 | 
             
            email:
         | 
| 267 | 
            -
            -  | 
| 253 | 
            +
            - rubyconvict@gmail.com
         | 
| 268 254 | 
             
            executables: []
         | 
| 269 255 | 
             
            extensions: []
         | 
| 270 256 | 
             
            extra_rdoc_files: []
         | 
| @@ -281,13 +267,11 @@ files: | |
| 281 267 | 
             
            - app/models/ajax_validator/concerns/validation.rb
         | 
| 282 268 | 
             
            - app/models/ajax_validator/validator.rb
         | 
| 283 269 | 
             
            - app/views/layouts/ajax_validator/application.html.erb
         | 
| 284 | 
            -
            - config/cucumber.yml
         | 
| 285 270 | 
             
            - config/routes.rb
         | 
| 286 271 | 
             
            - lib/ajax_validator.rb
         | 
| 287 272 | 
             
            - lib/ajax_validator/engine.rb
         | 
| 288 273 | 
             
            - lib/ajax_validator/version.rb
         | 
| 289 274 | 
             
            - lib/tasks/ajax_validator_tasks.rake
         | 
| 290 | 
            -
            - lib/tasks/cucumber.rake
         | 
| 291 275 | 
             
            - spec/dummy/README.rdoc
         | 
| 292 276 | 
             
            - spec/dummy/Rakefile
         | 
| 293 277 | 
             
            - spec/dummy/app/assets/javascripts/application.js
         | 
| @@ -328,6 +312,9 @@ files: | |
| 328 312 | 
             
            - spec/dummy/public/422.html
         | 
| 329 313 | 
             
            - spec/dummy/public/500.html
         | 
| 330 314 | 
             
            - spec/dummy/public/favicon.ico
         | 
| 315 | 
            +
            - spec/dummy/tmp/capybara/screenshot.html
         | 
| 316 | 
            +
            - spec/dummy/tmp/capybara/screenshot.png
         | 
| 317 | 
            +
            - spec/features/ajax_validator/example_spec.rb
         | 
| 331 318 | 
             
            - spec/rails_helper.rb
         | 
| 332 319 | 
             
            - spec/route_helper.rb
         | 
| 333 320 | 
             
            - spec/spec_helper.rb
         | 
| @@ -374,6 +361,8 @@ test_files: | |
| 374 361 | 
             
            - spec/dummy/app/assets/javascripts/application.js
         | 
| 375 362 | 
             
            - spec/dummy/log/development.log
         | 
| 376 363 | 
             
            - spec/dummy/log/test.log
         | 
| 364 | 
            +
            - spec/dummy/tmp/capybara/screenshot.png
         | 
| 365 | 
            +
            - spec/dummy/tmp/capybara/screenshot.html
         | 
| 377 366 | 
             
            - spec/dummy/db/test.sqlite3
         | 
| 378 367 | 
             
            - spec/dummy/db/schema.rb
         | 
| 379 368 | 
             
            - spec/dummy/db/development.sqlite3
         | 
| @@ -403,6 +392,7 @@ test_files: | |
| 403 392 | 
             
            - spec/dummy/public/404.html
         | 
| 404 393 | 
             
            - spec/route_helper.rb
         | 
| 405 394 | 
             
            - spec/rails_helper.rb
         | 
| 395 | 
            +
            - spec/features/ajax_validator/example_spec.rb
         | 
| 406 396 | 
             
            - spec/spec_helper.rb
         | 
| 407 397 | 
             
            - spec/support/database_cleaner.rb
         | 
| 408 398 | 
             
            - spec/support/factory_girl_rails.rb
         | 
    
        data/config/cucumber.yml
    DELETED
    
    | @@ -1,8 +0,0 @@ | |
| 1 | 
            -
            <%
         | 
| 2 | 
            -
            rerun = File.file?('rerun.txt') ? IO.read('rerun.txt') : ""
         | 
| 3 | 
            -
            rerun_opts = rerun.to_s.strip.empty? ? "--format #{ENV['CUCUMBER_FORMAT'] || 'progress'} features" : "--format #{ENV['CUCUMBER_FORMAT'] || 'pretty'} #{rerun}"
         | 
| 4 | 
            -
            std_opts = "--format #{ENV['CUCUMBER_FORMAT'] || 'pretty'} --strict --tags ~@wip"
         | 
| 5 | 
            -
            %>
         | 
| 6 | 
            -
            default: <%= std_opts %> features
         | 
| 7 | 
            -
            wip: --tags @wip:3 --wip features
         | 
| 8 | 
            -
            rerun: <%= rerun_opts %> --format rerun --out rerun.txt --strict --tags ~@wip
         | 
    
        data/lib/tasks/cucumber.rake
    DELETED
    
    | @@ -1,65 +0,0 @@ | |
| 1 | 
            -
            # IMPORTANT: This file is generated by cucumber-rails - edit at your own peril.
         | 
| 2 | 
            -
            # It is recommended to regenerate this file in the future when you upgrade to a 
         | 
| 3 | 
            -
            # newer version of cucumber-rails. Consider adding your own code to a new file 
         | 
| 4 | 
            -
            # instead of editing this one. Cucumber will automatically load all features/**/*.rb
         | 
| 5 | 
            -
            # files.
         | 
| 6 | 
            -
             | 
| 7 | 
            -
             | 
| 8 | 
            -
            unless ARGV.any? {|a| a =~ /^gems/} # Don't load anything when running the gems:* tasks
         | 
| 9 | 
            -
             | 
| 10 | 
            -
            vendored_cucumber_bin = Dir["#{Rails.root}/vendor/{gems,plugins}/cucumber*/bin/cucumber"].first
         | 
| 11 | 
            -
            $LOAD_PATH.unshift(File.dirname(vendored_cucumber_bin) + '/../lib') unless vendored_cucumber_bin.nil?
         | 
| 12 | 
            -
             | 
| 13 | 
            -
            begin
         | 
| 14 | 
            -
              require 'cucumber/rake/task'
         | 
| 15 | 
            -
             | 
| 16 | 
            -
              namespace :cucumber do
         | 
| 17 | 
            -
                Cucumber::Rake::Task.new({:ok => 'db:test:prepare'}, 'Run features that should pass') do |t|
         | 
| 18 | 
            -
                  t.binary = vendored_cucumber_bin # If nil, the gem's binary is used.
         | 
| 19 | 
            -
                  t.fork = true # You may get faster startup if you set this to false
         | 
| 20 | 
            -
                  t.profile = 'default'
         | 
| 21 | 
            -
                end
         | 
| 22 | 
            -
             | 
| 23 | 
            -
                Cucumber::Rake::Task.new({:wip => 'db:test:prepare'}, 'Run features that are being worked on') do |t|
         | 
| 24 | 
            -
                  t.binary = vendored_cucumber_bin
         | 
| 25 | 
            -
                  t.fork = true # You may get faster startup if you set this to false
         | 
| 26 | 
            -
                  t.profile = 'wip'
         | 
| 27 | 
            -
                end
         | 
| 28 | 
            -
             | 
| 29 | 
            -
                Cucumber::Rake::Task.new({:rerun => 'db:test:prepare'}, 'Record failing features and run only them if any exist') do |t|
         | 
| 30 | 
            -
                  t.binary = vendored_cucumber_bin
         | 
| 31 | 
            -
                  t.fork = true # You may get faster startup if you set this to false
         | 
| 32 | 
            -
                  t.profile = 'rerun'
         | 
| 33 | 
            -
                end
         | 
| 34 | 
            -
             | 
| 35 | 
            -
                desc 'Run all features'
         | 
| 36 | 
            -
                task :all => [:ok, :wip]
         | 
| 37 | 
            -
             | 
| 38 | 
            -
                task :statsetup do
         | 
| 39 | 
            -
                  require 'rails/code_statistics'
         | 
| 40 | 
            -
                  ::STATS_DIRECTORIES << %w(Cucumber\ features features) if File.exist?('features')
         | 
| 41 | 
            -
                  ::CodeStatistics::TEST_TYPES << "Cucumber features" if File.exist?('features')
         | 
| 42 | 
            -
                end
         | 
| 43 | 
            -
              end
         | 
| 44 | 
            -
              desc 'Alias for cucumber:ok'
         | 
| 45 | 
            -
              task :cucumber => 'cucumber:ok'
         | 
| 46 | 
            -
             | 
| 47 | 
            -
              task :default => :cucumber
         | 
| 48 | 
            -
             | 
| 49 | 
            -
              task :features => :cucumber do
         | 
| 50 | 
            -
                STDERR.puts "*** The 'features' task is deprecated. See rake -T cucumber ***"
         | 
| 51 | 
            -
              end
         | 
| 52 | 
            -
             | 
| 53 | 
            -
              # In case we don't have ActiveRecord, append a no-op task that we can depend upon.
         | 
| 54 | 
            -
              task 'db:test:prepare' do
         | 
| 55 | 
            -
              end
         | 
| 56 | 
            -
             | 
| 57 | 
            -
              task :stats => 'cucumber:statsetup'
         | 
| 58 | 
            -
            rescue LoadError
         | 
| 59 | 
            -
              desc 'cucumber rake task not available (cucumber not installed)'
         | 
| 60 | 
            -
              task :cucumber do
         | 
| 61 | 
            -
                abort 'Cucumber rake task is not available. Be sure to install cucumber as a gem or plugin'
         | 
| 62 | 
            -
              end
         | 
| 63 | 
            -
            end
         | 
| 64 | 
            -
             | 
| 65 | 
            -
            end
         |