Skip to content

Commit 384197e

Browse files
committed
Change /skmz/schemas to /skmz/info/schemas
1 parent 1360383 commit 384197e

File tree

7 files changed

+34
-28
lines changed

7 files changed

+34
-28
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ $ bundle
2626

2727
## Usage
2828

29-
Visit `/skmz/schemas` in your app.
29+
Visit `/skmz/info/schemas` in your app.
3030

3131
## Contributing
3232

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
module Skmz
2+
module Info
3+
class SchemasController < ActionController::Base
4+
def index
5+
@schema = Skmz::Schema.load
6+
end
7+
end
8+
end
9+
end

app/controllers/skmz/schemas_controller.rb

Lines changed: 0 additions & 7 deletions
This file was deleted.

lib/skmz/routing/mapper.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@ module ActionDispatch::Routing
22
class Mapper
33
def mount_skmz
44
namespace :skmz do
5-
resources :schemas, only: [:index]
5+
namespace :info do
6+
resources :schemas, only: [:index]
7+
end
68
end
79
end
810
end
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
require 'spec_helper'
2+
3+
module Skmz
4+
module Info
5+
describe SchemasController do
6+
describe "GET index" do
7+
it "assigns @schema" do
8+
schema = Schema.new
9+
Schema.should_receive(:load).and_return(schema)
10+
get :index
11+
expect(assigns(:schema)).to eq(schema)
12+
end
13+
14+
it "renders the index template" do
15+
get :index
16+
expect(response).to render_template('index')
17+
end
18+
end
19+
end
20+
end
21+
end

spec/controllers/skmz/schemas_controller_spec.rb

Lines changed: 0 additions & 19 deletions
This file was deleted.

0 commit comments

Comments
 (0)