UNPKG
@lolpix/react-hashrouter
Version:
latest (0.0.2)
0.0.2
0.0.1
A fluent hash based router for React apps
github.com/lolPix/react-hashrouter
lolPix/react-hashrouter
@lolpix/react-hashrouter
/
Link.test.js
11 lines
(9 loc)
•
298 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
import
React
from
'react'
;
import
Link
from
'./Link'
;
import
{ mount }
from
'enzyme'
;
describe
(
'<Link/>'
,
function
(
) {
it
(
'should map the given path to a hash url'
,
function
(
) {
const
wrapper =
mount
(
<
Link
to
=
"/test/"
/>
);
expect
(wrapper.
find
(
'a'
).
prop
(
'href'
) ===
'/#/test'
); }); });