shim 0.0.3 → 0.1.0
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.
- data/.gitignore +2 -0
 - data/Rakefile +7 -0
 - data/app/controllers/shim/pages_controller.rb +2 -2
 - data/lib/shim/version.rb +1 -1
 - data/shim.gemspec +3 -0
 - data/test/dummy/db/.gitkeep +0 -0
 - data/test/integration/routing_test.rb +19 -0
 - data/test/test_helper.rb +2 -0
 - metadata +38 -2
 
    
        data/Rakefile
    CHANGED
    
    
| 
         @@ -1,6 +1,6 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            class Shim::PagesController < ActionController::Base
         
     | 
| 
       2 
2 
     | 
    
         
             
              unloadable
         
     | 
| 
       3 
     | 
    
         
            -
              layout Proc.new { |_| Shim.layout }
         
     | 
| 
      
 3 
     | 
    
         
            +
              layout Proc.new { |_| ::Shim.layout }
         
     | 
| 
       4 
4 
     | 
    
         | 
| 
       5 
5 
     | 
    
         
             
              rescue_from ActionView::MissingTemplate do |exception|
         
     | 
| 
       6 
6 
     | 
    
         
             
                if exception.message =~ %r{Missing template #{content_path}}
         
     | 
| 
         @@ -26,6 +26,6 @@ class Shim::PagesController < ActionController::Base 
     | 
|
| 
       26 
26 
     | 
    
         
             
              end
         
     | 
| 
       27 
27 
     | 
    
         | 
| 
       28 
28 
     | 
    
         
             
              def content_path
         
     | 
| 
       29 
     | 
    
         
            -
                Shim.content_path
         
     | 
| 
      
 29 
     | 
    
         
            +
                ::Shim.content_path
         
     | 
| 
       30 
30 
     | 
    
         
             
              end
         
     | 
| 
       31 
31 
     | 
    
         
             
            end
         
     | 
    
        data/lib/shim/version.rb
    CHANGED
    
    
    
        data/shim.gemspec
    CHANGED
    
    
| 
         
            File without changes
         
     | 
| 
         @@ -0,0 +1,19 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            require 'test_helper'
         
     | 
| 
      
 2 
     | 
    
         
            +
             
     | 
| 
      
 3 
     | 
    
         
            +
            class RoutesTest < ActionDispatch::IntegrationTest
         
     | 
| 
      
 4 
     | 
    
         
            +
              def setup
         
     | 
| 
      
 5 
     | 
    
         
            +
                @routes = Shim::Engine.routes
         
     | 
| 
      
 6 
     | 
    
         
            +
              end
         
     | 
| 
      
 7 
     | 
    
         
            +
             
     | 
| 
      
 8 
     | 
    
         
            +
              def test_index_route
         
     | 
| 
      
 9 
     | 
    
         
            +
                assert_routing "", { :controller => "shim/pages", :action => "show", :id => "index" } 
         
     | 
| 
      
 10 
     | 
    
         
            +
              end
         
     | 
| 
      
 11 
     | 
    
         
            +
              
         
     | 
| 
      
 12 
     | 
    
         
            +
              def test_page_route
         
     | 
| 
      
 13 
     | 
    
         
            +
                assert_routing "some-page", { :controller => "shim/pages", :action => "show", :id => "some-page" }
         
     | 
| 
      
 14 
     | 
    
         
            +
              end
         
     | 
| 
      
 15 
     | 
    
         
            +
             
     | 
| 
      
 16 
     | 
    
         
            +
              def test_routes_with_slashes
         
     | 
| 
      
 17 
     | 
    
         
            +
                assert_routing "some/nested/path-thing", { :controller => "shim/pages", :action => "show", :id => "some/nested/path-thing" }
         
     | 
| 
      
 18 
     | 
    
         
            +
              end
         
     | 
| 
      
 19 
     | 
    
         
            +
            end
         
     | 
    
        data/test/test_helper.rb
    CHANGED
    
    
    
        metadata
    CHANGED
    
    | 
         @@ -1,7 +1,7 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            --- !ruby/object:Gem::Specification
         
     | 
| 
       2 
2 
     | 
    
         
             
            name: shim
         
     | 
| 
       3 
3 
     | 
    
         
             
            version: !ruby/object:Gem::Version
         
     | 
| 
       4 
     | 
    
         
            -
              version: 0.0 
     | 
| 
      
 4 
     | 
    
         
            +
              version: 0.1.0
         
     | 
| 
       5 
5 
     | 
    
         
             
              prerelease: 
         
     | 
| 
       6 
6 
     | 
    
         
             
            platform: ruby
         
     | 
| 
       7 
7 
     | 
    
         
             
            authors:
         
     | 
| 
         @@ -10,7 +10,7 @@ authors: 
     | 
|
| 
       10 
10 
     | 
    
         
             
            autorequire: 
         
     | 
| 
       11 
11 
     | 
    
         
             
            bindir: bin
         
     | 
| 
       12 
12 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       13 
     | 
    
         
            -
            date: 2012- 
     | 
| 
      
 13 
     | 
    
         
            +
            date: 2012-08-27 00:00:00.000000000 Z
         
     | 
| 
       14 
14 
     | 
    
         
             
            dependencies:
         
     | 
| 
       15 
15 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       16 
16 
     | 
    
         
             
              name: thor
         
     | 
| 
         @@ -76,6 +76,38 @@ dependencies: 
     | 
|
| 
       76 
76 
     | 
    
         
             
                - - ! '>='
         
     | 
| 
       77 
77 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       78 
78 
     | 
    
         
             
                    version: '0'
         
     | 
| 
      
 79 
     | 
    
         
            +
            - !ruby/object:Gem::Dependency
         
     | 
| 
      
 80 
     | 
    
         
            +
              name: sqlite3
         
     | 
| 
      
 81 
     | 
    
         
            +
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
      
 82 
     | 
    
         
            +
                none: false
         
     | 
| 
      
 83 
     | 
    
         
            +
                requirements:
         
     | 
| 
      
 84 
     | 
    
         
            +
                - - ! '>='
         
     | 
| 
      
 85 
     | 
    
         
            +
                  - !ruby/object:Gem::Version
         
     | 
| 
      
 86 
     | 
    
         
            +
                    version: '0'
         
     | 
| 
      
 87 
     | 
    
         
            +
              type: :development
         
     | 
| 
      
 88 
     | 
    
         
            +
              prerelease: false
         
     | 
| 
      
 89 
     | 
    
         
            +
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
      
 90 
     | 
    
         
            +
                none: false
         
     | 
| 
      
 91 
     | 
    
         
            +
                requirements:
         
     | 
| 
      
 92 
     | 
    
         
            +
                - - ! '>='
         
     | 
| 
      
 93 
     | 
    
         
            +
                  - !ruby/object:Gem::Version
         
     | 
| 
      
 94 
     | 
    
         
            +
                    version: '0'
         
     | 
| 
      
 95 
     | 
    
         
            +
            - !ruby/object:Gem::Dependency
         
     | 
| 
      
 96 
     | 
    
         
            +
              name: pry
         
     | 
| 
      
 97 
     | 
    
         
            +
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
      
 98 
     | 
    
         
            +
                none: false
         
     | 
| 
      
 99 
     | 
    
         
            +
                requirements:
         
     | 
| 
      
 100 
     | 
    
         
            +
                - - ! '>='
         
     | 
| 
      
 101 
     | 
    
         
            +
                  - !ruby/object:Gem::Version
         
     | 
| 
      
 102 
     | 
    
         
            +
                    version: '0'
         
     | 
| 
      
 103 
     | 
    
         
            +
              type: :development
         
     | 
| 
      
 104 
     | 
    
         
            +
              prerelease: false
         
     | 
| 
      
 105 
     | 
    
         
            +
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
      
 106 
     | 
    
         
            +
                none: false
         
     | 
| 
      
 107 
     | 
    
         
            +
                requirements:
         
     | 
| 
      
 108 
     | 
    
         
            +
                - - ! '>='
         
     | 
| 
      
 109 
     | 
    
         
            +
                  - !ruby/object:Gem::Version
         
     | 
| 
      
 110 
     | 
    
         
            +
                    version: '0'
         
     | 
| 
       79 
111 
     | 
    
         
             
            description: Shim is a small CMS built as a Rails engine.
         
     | 
| 
       80 
112 
     | 
    
         
             
            email:
         
     | 
| 
       81 
113 
     | 
    
         
             
            - mikey.utley@gmail.com
         
     | 
| 
         @@ -133,6 +165,7 @@ files: 
     | 
|
| 
       133 
165 
     | 
    
         
             
            - test/dummy/config/initializers/wrap_parameters.rb
         
     | 
| 
       134 
166 
     | 
    
         
             
            - test/dummy/config/locales/en.yml
         
     | 
| 
       135 
167 
     | 
    
         
             
            - test/dummy/config/routes.rb
         
     | 
| 
      
 168 
     | 
    
         
            +
            - test/dummy/db/.gitkeep
         
     | 
| 
       136 
169 
     | 
    
         
             
            - test/dummy/lib/assets/.gitkeep
         
     | 
| 
       137 
170 
     | 
    
         
             
            - test/dummy/log/.gitkeep
         
     | 
| 
       138 
171 
     | 
    
         
             
            - test/dummy/public/404.html
         
     | 
| 
         @@ -141,6 +174,7 @@ files: 
     | 
|
| 
       141 
174 
     | 
    
         
             
            - test/dummy/public/favicon.ico
         
     | 
| 
       142 
175 
     | 
    
         
             
            - test/dummy/script/rails
         
     | 
| 
       143 
176 
     | 
    
         
             
            - test/integration/navigation_test.rb
         
     | 
| 
      
 177 
     | 
    
         
            +
            - test/integration/routing_test.rb
         
     | 
| 
       144 
178 
     | 
    
         
             
            - test/shim_test.rb
         
     | 
| 
       145 
179 
     | 
    
         
             
            - test/test_helper.rb
         
     | 
| 
       146 
180 
     | 
    
         
             
            homepage: ''
         
     | 
| 
         @@ -194,6 +228,7 @@ test_files: 
     | 
|
| 
       194 
228 
     | 
    
         
             
            - test/dummy/config/initializers/wrap_parameters.rb
         
     | 
| 
       195 
229 
     | 
    
         
             
            - test/dummy/config/locales/en.yml
         
     | 
| 
       196 
230 
     | 
    
         
             
            - test/dummy/config/routes.rb
         
     | 
| 
      
 231 
     | 
    
         
            +
            - test/dummy/db/.gitkeep
         
     | 
| 
       197 
232 
     | 
    
         
             
            - test/dummy/lib/assets/.gitkeep
         
     | 
| 
       198 
233 
     | 
    
         
             
            - test/dummy/log/.gitkeep
         
     | 
| 
       199 
234 
     | 
    
         
             
            - test/dummy/public/404.html
         
     | 
| 
         @@ -202,5 +237,6 @@ test_files: 
     | 
|
| 
       202 
237 
     | 
    
         
             
            - test/dummy/public/favicon.ico
         
     | 
| 
       203 
238 
     | 
    
         
             
            - test/dummy/script/rails
         
     | 
| 
       204 
239 
     | 
    
         
             
            - test/integration/navigation_test.rb
         
     | 
| 
      
 240 
     | 
    
         
            +
            - test/integration/routing_test.rb
         
     | 
| 
       205 
241 
     | 
    
         
             
            - test/shim_test.rb
         
     | 
| 
       206 
242 
     | 
    
         
             
            - test/test_helper.rb
         
     |