Files
onemdm-server/spec/controllers/devices_controller_spec.rb
Yedhu Krishnan 97bc55a518 Create device controller with and API to create a device
- Turn of assets and helper generation automatically
2015-10-17 11:33:31 +05:30

15 lines
335 B
Ruby

require 'rails_helper'
RSpec.describe DevicesController, type: :controller do
describe "POST #create" do
it "creates a device" do
expect {
post :create, device: attributes_for(:device), format: :json
}.to change{ Device.count }.by(1)
#expect(response).to have_http_status(:success)
end
end
end