File tree Expand file tree Collapse file tree 2 files changed +30
-0
lines changed Expand file tree Collapse file tree 2 files changed +30
-0
lines changed Original file line number Diff line number Diff line change
1
+ 'use strict' ;
2
+
3
+ export const SET_FULLSCREEN = 'SET_FULLSCREEN' ;
4
+
5
+ export function setFullscreen ( fullscreen ) {
6
+ return {
7
+ type : SET_FULLSCREEN ,
8
+ fullscreen : fullscreen
9
+ } ;
10
+ }
Original file line number Diff line number Diff line change
1
+ 'use strict' ;
2
+
3
+ import assert from 'assert' ;
4
+ import { SET_FULLSCREEN , setFullscreen } from '../../app/actions/setFullscreen' ;
5
+
6
+ describe ( 'setFullscreen' , ( ) => {
7
+ it ( 'returns an object with fullscreen: true' , ( ) => {
8
+ const action = setFullscreen ( true ) ;
9
+
10
+ assert . equal ( action . type , SET_FULLSCREEN ) ;
11
+ assert . equal ( action . fullscreen , true ) ;
12
+ } ) ;
13
+
14
+ it ( 'returns an object with fullscreen: false' , ( ) => {
15
+ const action = setFullscreen ( false ) ;
16
+
17
+ assert . equal ( action . type , SET_FULLSCREEN ) ;
18
+ assert . equal ( action . fullscreen , false ) ;
19
+ } ) ;
20
+ } ) ;
You can’t perform that action at this time.
0 commit comments