@@ -1067,7 +1067,7 @@ describe('Test sunburst restyle:', function() {
10671067 . then ( done ) ;
10681068 } ) ;
10691069
1070- it ( 'should be able to restyle *textinfo*' , function ( done ) {
1070+ it ( 'should be able to restyle *textinfo* with various *insidetextorientation* ' , function ( done ) {
10711071 var mock = {
10721072 data : [ {
10731073 type : 'sunburst' ,
@@ -1121,6 +1121,27 @@ describe('Test sunburst restyle:', function() {
11211121 . then ( _assert ( 'show everything' , [ 'Root\n0\nnode0' , 'B\n2\nnode2' , 'A\n1\nnode1' , 'b\n3\nnode3' ] ) )
11221122 . then ( _restyle ( { textinfo : null } ) )
11231123 . then ( _assert ( 'back to dflt' , [ 'Root\nnode0' , 'B\nnode2' , 'A\nnode1' , 'b\nnode3' ] ) )
1124+ // now change insidetextorientation to 'horizontal'
1125+ . then ( _restyle ( { insidetextorientation : 'horizontal' } ) )
1126+ . then ( _assert ( 'back to dflt' , [ 'Root\nnode0' , 'B\nnode2' , 'A\nnode1' , 'b\nnode3' ] ) )
1127+ . then ( _restyle ( { textinfo : 'none' } ) )
1128+ . then ( _assert ( 'no textinfo' , [ '' , '' , '' , '' ] ) )
1129+ . then ( _restyle ( { textinfo : null } ) )
1130+ . then ( _assert ( 'back to dflt' , [ 'Root\nnode0' , 'B\nnode2' , 'A\nnode1' , 'b\nnode3' ] ) )
1131+ // now change insidetextorientation to 'tangential'
1132+ . then ( _restyle ( { insidetextorientation : 'tangential' } ) )
1133+ . then ( _assert ( 'back to dflt' , [ 'Root\nnode0' , 'B\nnode2' , 'A\nnode1' , 'b\nnode3' ] ) )
1134+ . then ( _restyle ( { textinfo : 'none' } ) )
1135+ . then ( _assert ( 'no textinfo' , [ '' , '' , '' , '' ] ) )
1136+ . then ( _restyle ( { textinfo : null } ) )
1137+ . then ( _assert ( 'back to dflt' , [ 'Root\nnode0' , 'B\nnode2' , 'A\nnode1' , 'b\nnode3' ] ) )
1138+ // now change insidetextorientation to 'radial'
1139+ . then ( _restyle ( { insidetextorientation : 'radial' } ) )
1140+ . then ( _assert ( 'back to dflt' , [ 'Root\nnode0' , 'B\nnode2' , 'A\nnode1' , 'b\nnode3' ] ) )
1141+ . then ( _restyle ( { textinfo : 'none' } ) )
1142+ . then ( _assert ( 'no textinfo' , [ '' , '' , '' , '' ] ) )
1143+ . then ( _restyle ( { textinfo : null } ) )
1144+ . then ( _assert ( 'back to dflt' , [ 'Root\nnode0' , 'B\nnode2' , 'A\nnode1' , 'b\nnode3' ] ) )
11241145 . catch ( failTest )
11251146 . then ( done ) ;
11261147 } ) ;
0 commit comments