Skip to content

Conversation

@joshsmith
Copy link
Contributor

@joshsmith joshsmith commented Nov 6, 2017

What's in this PR?

  • Moves :archived casting up into changeset since it can happen on creation (e.g. importing from GitHub)
  • Removes any task_list_id or order when archived
  • Moves required validation on task_list_id to only the case when task is not archived

References

Fixes #1150
Fixes #1154

@joshsmith joshsmith force-pushed the 1150-1154-archived-tasks-dont-need-lists-or-order branch from 02423b3 to a8d5f7c Compare November 6, 2017 00:22
@joshsmith joshsmith added this to the 📥 GitHub project syncing milestone Nov 6, 2017
Copy link
Contributor

@snewcomer snewcomer left a comment

Choose a reason for hiding this comment

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

nice!


# We really want to test the order is set, but we have no good way to
# test this since the column default is `0`
assert order !== 0
Copy link
Contributor

Choose a reason for hiding this comment

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

Ah so assert order fails. Would have thought since refute only handles nil and false that assert would have worked! 🚶‍♂️

Copy link
Contributor Author

Choose a reason for hiding this comment

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

assert order succeeds but that's insufficient to tell us anything. Since the default is 0 it could just be set to 0, but instead it will receive a random ranked value from EctoOrdered.

@joshsmith joshsmith merged commit ead9892 into develop Nov 6, 2017
@joshsmith joshsmith deleted the 1150-1154-archived-tasks-dont-need-lists-or-order branch November 6, 2017 03:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants