@@ -3,7 +3,7 @@ import React from 'react'
3
3
import Match from '../Match'
4
4
import { renderToString } from 'react-dom/server'
5
5
import { render } from 'react-dom'
6
- import { LocationEmitter } from '../locationEmission '
6
+ import { LocationBroadcast } from '../locationBroadcast '
7
7
8
8
describe ( 'Match' , ( ) => {
9
9
const TEXT = 'TEXT'
@@ -277,11 +277,11 @@ describe('Match', () => {
277
277
const TEXT = 'TEXT'
278
278
const location = { pathname : '/' , state : { test : TEXT } }
279
279
const html = renderToString (
280
- < LocationEmitter value = { location } >
280
+ < LocationBroadcast value = { location } >
281
281
< Match pattern = "/" render = { ( { location } ) => (
282
282
< div > { location . state . test } </ div >
283
283
) } />
284
- </ LocationEmitter >
284
+ </ LocationBroadcast >
285
285
)
286
286
expect ( html ) . toContain ( TEXT )
287
287
} )
@@ -293,11 +293,11 @@ describe('Match', () => {
293
293
const contextLoc = { pathname : '/' , state : { test : CONTEXT } }
294
294
const propsLoc = { pathname : '/' , state : { test : PROP } }
295
295
const html = renderToString (
296
- < LocationEmitter value = { contextLoc } >
296
+ < LocationBroadcast value = { contextLoc } >
297
297
< Match location = { propsLoc } pattern = "/" render = { ( { location } ) => (
298
298
< div > { location . state . test } </ div >
299
299
) } />
300
- </ LocationEmitter >
300
+ </ LocationBroadcast >
301
301
)
302
302
expect ( html ) . toNotContain ( CONTEXT )
303
303
expect ( html ) . toContain ( PROP )
0 commit comments