File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -292,7 +292,7 @@ describe('ChainlinkDataStreamsConsumer', function () {
292292 const client = new ChainlinkDataStreamsConsumer ( config ) ;
293293 delete client . apiUrl
294294 assert . rejects ( ( ) => { client . fetch ( ) } )
295- } )
295+ } ) ;
296296
297297 it ( "can't subscribe to feeds without wsUrl" , function ( ) {
298298 assert . doesNotThrow ( ( ) => {
@@ -301,7 +301,14 @@ describe('ChainlinkDataStreamsConsumer', function () {
301301 assert . throws ( ( ) => {
302302 new ChainlinkDataStreamsConsumer ( { ...config , wsUrl : null , feeds : [ '0x0' ] } ) ;
303303 } ) ;
304- } )
304+ } ) ;
305+
306+ it ( "doesn't allow connectedFeeds to be mutated directly" , function ( ) {
307+ const client = new ChainlinkDataStreamsConsumer ( config ) ;
308+ assert . throws ( ( ) => client . feeds . add ( '0x0' ) ) ;
309+ assert . throws ( ( ) => client . feeds . delete ( '0x0' ) ) ;
310+ assert . throws ( ( ) => client . feeds . clear ( ) ) ;
311+ } ) ;
305312
306313 it ( 'should fetch a report for a single feed and validate the instance' , async function ( ) {
307314 for ( const feed of feedIds ) {
You can’t perform that action at this time.
0 commit comments