aboutsummaryrefslogtreecommitdiffstats
path: root/actioncable/test/javascript/src/test_helpers
diff options
context:
space:
mode:
Diffstat (limited to 'actioncable/test/javascript/src/test_helpers')
-rw-r--r--actioncable/test/javascript/src/test_helpers/consumer_test_helper.js4
-rw-r--r--actioncable/test/javascript/src/test_helpers/index.js6
2 files changed, 5 insertions, 5 deletions
diff --git a/actioncable/test/javascript/src/test_helpers/consumer_test_helper.js b/actioncable/test/javascript/src/test_helpers/consumer_test_helper.js
index f1abea331b..d1dabc9fc4 100644
--- a/actioncable/test/javascript/src/test_helpers/consumer_test_helper.js
+++ b/actioncable/test/javascript/src/test_helpers/consumer_test_helper.js
@@ -1,5 +1,5 @@
import { WebSocket as MockWebSocket, Server as MockServer } from "mock-socket"
-import ActionCable from "../../../../app/javascript/action_cable/index"
+import * as ActionCable from "../../../../app/javascript/action_cable/index"
import {defer, testURL} from "./index"
export default function(name, options, callback) {
@@ -14,7 +14,7 @@ export default function(name, options, callback) {
return QUnit.test(name, function(assert) {
const doneAsync = assert.async()
- ActionCable.WebSocket = MockWebSocket
+ ActionCable.adapters.WebSocket = MockWebSocket
const server = new MockServer(options.url)
const consumer = ActionCable.createConsumer(options.url)
diff --git a/actioncable/test/javascript/src/test_helpers/index.js b/actioncable/test/javascript/src/test_helpers/index.js
index 5fa46c21ae..0cd4e260b3 100644
--- a/actioncable/test/javascript/src/test_helpers/index.js
+++ b/actioncable/test/javascript/src/test_helpers/index.js
@@ -1,4 +1,4 @@
-import ActionCable from "../../../../app/javascript/action_cable/index"
+import * as ActionCable from "../../../../app/javascript/action_cable/index"
export const testURL = "ws://cable.example.com/"
@@ -6,5 +6,5 @@ export function defer(callback) {
setTimeout(callback, 1)
}
-const originalWebSocket = ActionCable.WebSocket
-QUnit.testDone(() => ActionCable.WebSocket = originalWebSocket)
+const originalWebSocket = ActionCable.adapters.WebSocket
+QUnit.testDone(() => ActionCable.adapters.WebSocket = originalWebSocket)