DEV: new API s/replaceCurrentUser/updateCurrentUser

approved
#1

DEV: new API s/replaceCurrentUser/updateCurrentUser

diff --git a/test/javascripts/acceptance/self-approve-desktop-test.js.es6 b/test/javascripts/acceptance/self-approve-desktop-test.js.es6
index fa8346e..c894654 100644
--- a/test/javascripts/acceptance/self-approve-desktop-test.js.es6
+++ b/test/javascripts/acceptance/self-approve-desktop-test.js.es6
@@ -1,4 +1,4 @@
-import { replaceCurrentUser, acceptance } from "helpers/qunit-helpers";
+import { updateCurrentUser, acceptance } from "helpers/qunit-helpers";
 import Fixtures from "fixtures/topic";
 
 acceptance("review desktop", {
@@ -25,7 +25,7 @@ QUnit.test("shows approve button by default", async assert => {
 });
 
 QUnit.test("hides approve button if user is self", async assert => {
-  replaceCurrentUser({ id: 1 });
+  updateCurrentUser({ id: 1 });
 
   await visit("/t/this-is-a-test-topic/9/1");
 
diff --git a/test/javascripts/acceptance/self-approve-mobile-test.js.es6 b/test/javascripts/acceptance/self-approve-mobile-test.js.es6
index f0ea9d1..9622eb2 100644
--- a/test/javascripts/acceptance/self-approve-mobile-test.js.es6
+++ b/test/javascripts/acceptance/self-approve-mobile-test.js.es6
@@ -1,5 +1,5 @@
 import selectKit from "helpers/select-kit-helper";
-import { replaceCurrentUser, acceptance } from "helpers/qunit-helpers";
+import { updateCurrentUser, acceptance } from "helpers/qunit-helpers";
 import Fixtures from "fixtures/topic";
 
 acceptance("review mobile", {
@@ -30,7 +30,7 @@ QUnit.test("shows approve button by default", async assert => {
 });
 
 QUnit.test("hides approve button if user is self", async assert => {
-  replaceCurrentUser({ id: 1 });
+  updateCurrentUser({ id: 1 });
 
   await visit("/t/this-is-a-test-topic/9/1");

GitHub sha: f161b0c9

1 Like
Approved #2