1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/actioncable/test
Richard Macklin ac8ffbe76a Replace window references in ActionCable with self
Before this change, attempting to use ActionCable inside a web worker
would result in an exception being thrown:
```
ReferenceError: window is not defined
```

By replacing the `window` reference with `self`, which is available in
both a window context and a worker context, we can avoid this error.

Ref:
https://developer.mozilla.org/en-US/docs/Web/API/Window/self
2019-01-14 17:44:35 -08:00
..
channel Merge pull request #34740 from sponomarev/feature/assert_has_stream 2018-12-31 11:12:01 -05:00
connection Update Action Cable connection testing. 2019-01-14 01:19:56 +01:00
javascript/src Replace window references in ActionCable with self 2019-01-14 17:44:35 -08:00
server Enable Style/RedundantBegin cop to avoid newly adding redundant begin block 2018-12-21 06:12:42 +09:00
stubs Remove redundant accessors 2018-06-11 16:39:50 +02:00
subscription_adapter Fix test case to ensure default connection id is filled 2018-09-07 04:00:00 +09:00
client_test.rb Include ActiveSupport::Testing::MethodCallAssertions to ActionCable::TestCase 2018-06-08 23:29:05 +03:00
test_helper.rb Simplify configuring of ActionCable.server.config.logger for actioncable tests 2018-08-23 12:36:19 +03:00
test_helper_test.rb DRY in assert_broadcasts 2018-08-23 12:39:03 +03:00
worker_test.rb Inherit all actioncable's test classes from ActionCable::TestCase 2018-06-08 23:23:06 +03:00