We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f82f9cd commit 41a6ca5Copy full SHA for 41a6ca5
test/lib/code_corps/github/sync/sync_test.exs
@@ -120,6 +120,12 @@ defmodule CodeCorps.GitHub.SyncTest do
120
assert Repo.aggregate(Task, :count, :id) == 8
121
assert Repo.aggregate(User, :count, :id) == 13
122
123
+ # Simulate disconnecting the repo and updating a task locally
124
+
125
+ [task | _] = Repo.all(Task, limit: 1)
126
+ changeset = Task.update_changeset(task, %{title: "New title", updated_from: "codecorps"})
127
+ Repo.update!(changeset)
128
129
# Sync a second time – should run without trouble
130
131
Sync.sync_repo(github_repo)
0 commit comments