We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5cd7a7a commit 7fa08afCopy full SHA for 7fa08af
1 file changed
tests/RecordingListener.cfc
@@ -14,11 +14,11 @@ component hint="Test fixture — records every callback invocation for assertion
14
arrayAppend( variables.events, "onClose" );
15
}
16
17
- function onError( type, cause, data ) {
18
- var entry = "onError:" & arguments.type;
19
- if ( structKeyExists( arguments, "data" ) && !isNull( arguments.data ) )
20
- entry &= ":withData";
21
- arrayAppend( variables.events, entry );
+ function onError( type, cause ) {
+ // Match the 2-arg signature the existing WebSocketListener uses. The 3rd
+ // `data` arg is only populated for `message`-type errors; if we need to
+ // test that later, add a separate fixture.
+ arrayAppend( variables.events, "onError:" & arguments.type );
22
23
24
function onPing() {
0 commit comments