File tree 3 files changed +32
-1
lines changed
3 files changed +32
-1
lines changed Original file line number Diff line number Diff line change
1
+ to debug test, run
2
+
3
+ ``` sh
4
+ ./node_modules/.bin/karma start --no-single-run --browsers Chrome
5
+ ```
6
+ then click debug and press F12 to launch Chrome Developer Tools
7
+
8
+ to run test in ci mode, run
9
+
10
+ ``` sh
11
+ npm run test:watch
12
+ ```
13
+ Tests runs in headless Chromium downloaded by Puppeteer.
Original file line number Diff line number Diff line change
1
+ import { appWrapper } from 'helpers/fullRenderHelper'
2
+
3
+ describe ( 'styler > quick' , ( ) => {
4
+ it ( 'should change style when hover mouse over palette #1' , ( ) => {
5
+ let otSlide = $ ( '.sp-operating-table .sp-ot-slide' )
6
+ const originalStyle = otSlide . css ( 'background' ) . slice ( 0 )
7
+ let palette1Dom = $ (
8
+ '.sp-navbar-style #sp-quick-styler > .sp-palette[title="palette 1"]'
9
+ )
10
+ let palette1 = appWrapper . find (
11
+ '.sp-navbar-style #sp-quick-styler > .sp-palette[title="palette 1"]'
12
+ )
13
+ palette1 . simulate ( 'mouseover' )
14
+ expect ( otSlide . css ( 'background' ) ) . to . equal ( palette1Dom . css ( 'background' ) )
15
+ palette1 . simulate ( 'mouseleave' )
16
+ expect ( otSlide . css ( 'background' ) ) . to . equal ( originalStyle )
17
+ } )
18
+ } )
Original file line number Diff line number Diff line change 1
1
import { appWrapper } from 'helpers/fullRenderHelper'
2
2
3
3
describe ( 'widgets > controls > rotate' , ( ) => {
4
- it ( 'should rotate 90° cw along z axis' , ( ) => {
4
+ it ( 'should rotate about 90° cw along z axis' , ( ) => {
5
5
let domComponent = $ ( '.sp-operating-table .sp-ot-slide .sp-component:first' )
6
6
expect (
7
7
domComponent . find ( '.sp-edit-ctrls .rotate-z span:first' ) . text ( )
You can’t perform that action at this time.
0 commit comments