Created
January 6, 2014 18:44
-
-
Save jcoyne/8287438 to your computer and use it in GitHub Desktop.
DownloadsController spec
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'spec_helper' | |
| describe DownloadsController do | |
| let(:technote) { Technote.new("title" => "MyString") } | |
| let(:user) {User.create!(email: '[email protected]', password: 'drowssap')} | |
| before do | |
| sign_in user | |
| technote.read_users = [user.user_key] | |
| technote.technoteContent.content = "My ds content" | |
| technote.save! | |
| end | |
| it "should go" do | |
| get :show, id: technote, datastream_id: 'technoteContent' | |
| expect(response).to be_successful | |
| expect(response.body).to eq "My ds content" | |
| end | |
| end | |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Make sure your spec/spec_helper.rb has this line, so that
sign_inis defined.