Skip to content

Commit 95b827b

Browse files
committed
add unhover action creator
1 parent 583847f commit 95b827b

2 files changed

Lines changed: 16 additions & 0 deletions

File tree

__tests__/action.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import {
22
HOVER,
33
UNHOVER,
44
hover,
5+
unhover,
56
} from '../src/action';
67

78
describe('action', () => {
@@ -23,4 +24,14 @@ describe('action', () => {
2324
});
2425
});
2526
});
27+
describe('unhover', () => {
28+
it('should create expected action', () => {
29+
const id = 'some id';
30+
expect(unhover(id))
31+
.toEqual({
32+
type: UNHOVER,
33+
id,
34+
});
35+
});
36+
});
2637
});

src/action.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,8 @@ export const hover = id => ({
55
type: HOVER,
66
id,
77
});
8+
9+
export const unhover = id => ({
10+
type: UNHOVER,
11+
id,
12+
});

0 commit comments

Comments
 (0)