Skip to content

Conversation

@begedin
Copy link
Contributor

@begedin begedin commented Aug 15, 2016

Closes #32

user = insert_user
changeset = Preview.changeset(%Preview{}, %{markdown: "A **strong** element"}, user)
assert changeset.valid?
assert Ecto.Changeset.get_change(changeset, :user).data == user
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We use put_assoc, so get_change for :user is another Ecto.Changeset, with no changes and the data field populated with the user

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Funny typo in the test string.

@begedin begedin force-pushed the 32-add-previews-api branch from 3a93757 to 7f32a6d Compare August 15, 2016 13:47
@joshsmith joshsmith merged commit 7e950da into develop Aug 15, 2016
@joshsmith joshsmith deleted the 32-add-previews-api branch August 15, 2016 21:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants