@samitouri / QOS-React / commits / c1daa6f2c1

Record tests and fix BrowserEventEmitter test to not crash jest

Sebastian Markbage committed Nov 18, 2016 at 18:08 UTC c1daa6f2c1f6a6e3a771185d0decb6484f0a4c0b
4 files changed +62 -66
scripts/fiber/tests-failing.txt
-53
@@ -42,7 +42,6 @@ src/renderers/dom/shared/__tests__/ReactBrowserEventEmitter-test.js
42 * should have mouse enter simulated by test utils
43 * should infer onTouchTap from a touchStart/End
44 * should infer onTouchTap from when dragging below threshold
45 -* should not onTouchTap from when dragging beyond threshold
45 * should bubble onTouchTap
46
47 src/renderers/dom/shared/__tests__/ReactDOMComponent-test.js
@@ -66,65 +65,28 @@ src/renderers/dom/shared/__tests__/ReactDOMTextComponent-test.js
65 * can reconcile text arbitrarily split into multiple nodes on some substitutions only
66
67 src/renderers/dom/shared/__tests__/ReactEventIndependence-test.js
69 -* does not crash with other react inside
70 -* does not crash with other react outside
68 * does not when event fired on unmounted tree
69
70 src/renderers/dom/shared/__tests__/ReactEventListener-test.js
71 * should batch between handlers from different roots
72 * should not fire duplicate events for a React DOM tree
73
77 -src/renderers/dom/shared/__tests__/inputValueTracking-test.js
78 -* should stop tracking
79 -
74 src/renderers/dom/shared/eventPlugins/__tests__/ChangeEventPlugin-test.js
81 -* should fire change for checkbox input
82 -* should not fire change when setting the value programmatically
75 * should not fire change when setting checked programmatically
84 -* should only fire change for checked radio button once
85 -* should deduplicate input value change events
86 -* should listen for both change and input events when supported
87 -* should only fire events when the value changes for range inputs
88 -
89 -src/renderers/dom/shared/eventPlugins/__tests__/SelectEventPlugin-test.js
90 -* should skip extraction if no listeners are present
91 -* should extract if an `onSelect` listener is present
76
77 src/renderers/dom/shared/eventPlugins/__tests__/SimpleEventPlugin-test.js
94 -* A non-interactive tags click when disabled
78 * A non-interactive tags clicks bubble when disabled
96 -* should forward clicks when it starts out not disabled
79 * should not forward clicks when it starts out disabled
98 -* should forward clicks when it becomes not disabled
80 * should not forward clicks when it becomes disabled
100 -* should work correctly if the listener is changed
101 -* should forward clicks when it starts out not disabled
81 * should not forward clicks when it starts out disabled
103 -* should forward clicks when it becomes not disabled
82 * should not forward clicks when it becomes disabled
105 -* should work correctly if the listener is changed
106 -* should forward clicks when it starts out not disabled
83 * should not forward clicks when it starts out disabled
108 -* should forward clicks when it becomes not disabled
84 * should not forward clicks when it becomes disabled
110 -* should work correctly if the listener is changed
111 -* should forward clicks when it starts out not disabled
85 * should not forward clicks when it starts out disabled
113 -* should forward clicks when it becomes not disabled
86 * should not forward clicks when it becomes disabled
115 -* should work correctly if the listener is changed
116 -
117 -src/renderers/dom/shared/wrappers/__tests__/ReactDOMIframe-test.js
118 -* should trigger load events
87
88 src/renderers/dom/shared/wrappers/__tests__/ReactDOMInput-test.js
89 * should control a value in reentrant events
122 -* should update `defaultValue` for uncontrolled input
123 -* should update `defaultValue` for uncontrolled date/time input
124 -* should have the correct target value
125 -* should update defaultValue to empty string
126 -* sets type, step, min, max before value always
127 -* resets value of date/time input to fix bugs in iOS Safari
90
91 src/renderers/dom/shared/wrappers/__tests__/ReactDOMOption-test.js
92 * should allow ignoring `value` on option
@@ -136,25 +98,13 @@ src/renderers/dom/shared/wrappers/__tests__/ReactDOMSelect-test.js
98 * should allow setting `value`
99 * should allow setting `value` with multiple
100 * should not select other options automatically
139 -* should reset child options selected when they are changed and `value` is set
101 * should allow setting `value` with `objectToString`
102 * should allow switching to multiple
103 * should allow switching from multiple
104 * should remember value when switching to uncontrolled
144 -* should remember updated value when switching to uncontrolled
105 * should not control defaultValue if readding options
106 * should select grandchild options nested inside an optgroup
107
148 -src/renderers/dom/shared/wrappers/__tests__/ReactDOMTextarea-test.js
149 -* should set defaultValue
150 -* should update defaultValue to empty string
151 -* should allow setting `value` to `giraffe`
152 -* should allow setting `value` to `true`
153 -* should allow setting `value` to `false`
154 -* should allow setting `value` to `objToString`
155 -* should not incur unnecessary DOM mutations
156 -* should keep value when switching to uncontrolled element if changed
157 -
108 src/renderers/dom/stack/client/__tests__/ReactDOM-test.js
109 * throws in render() if the mount callback is not a function
110 * throws in render() if the update callback is not a function
@@ -287,9 +237,6 @@ src/renderers/shared/hooks/__tests__/ReactHostOperationHistoryHook-test.js
237 * gets reported when a child is inserted
238 * gets reported when a child is removed
239
290 -src/renderers/shared/shared/event/__tests__/EventPluginHub-test.js
291 -* should not prevent null listeners, at dispatch
292 -
240 src/renderers/shared/stack/reconciler/__tests__/ReactComponent-test.js
241 * should throw on invalid render targets
242 * throws usefully when rendering badly-typed elements
scripts/fiber/tests-passing-except-dev.txt
-10
@@ -27,7 +27,6 @@ src/renderers/dom/shared/__tests__/ReactDOMComponent-test.js
27 * should warn for unknown prop
28 * should group multiple unknown prop warnings together
29 * should warn for onDblClick prop
30 -* should work error event on <source> element
30 * should emit a warning once for a named custom component using shady DOM
31 * should not warn when server-side rendering `onScroll`
32 * warns on invalid nesting
@@ -48,17 +47,8 @@ src/renderers/dom/shared/__tests__/ReactDOMInvalidARIAHook-test.js
47
48 src/renderers/dom/shared/wrappers/__tests__/ReactDOMInput-test.js
49 * should warn if value is null
51 -* should warn if controlled input switches to uncontrolled (value is undefined)
50 * should warn if controlled input switches to uncontrolled (value is null)
53 -* should warn if controlled input switches to uncontrolled with defaultValue
51 * should warn if uncontrolled input (value is null) switches to controlled
55 -* should warn if controlled checkbox switches to uncontrolled (checked is undefined)
56 -* should warn if controlled checkbox switches to uncontrolled (checked is null)
57 -* should warn if controlled checkbox switches to uncontrolled with defaultChecked
58 -* should warn if controlled radio switches to uncontrolled (checked is undefined)
59 -* should warn if controlled radio switches to uncontrolled (checked is null)
60 -* should warn if controlled radio switches to uncontrolled with defaultChecked
61 -* should warn if radio checked false changes to become uncontrolled
52
53 src/renderers/dom/shared/wrappers/__tests__/ReactDOMSelect-test.js
54 * should warn if value is null
scripts/fiber/tests-passing.txt
+59
@@ -531,6 +531,7 @@ src/renderers/dom/shared/__tests__/ReactBrowserEventEmitter-test.js
531 * should stop after first dispatch if stopPropagation
532 * should invoke handlers that were removed while bubbling
533 * should not invoke newly inserted handlers while bubbling
534 +* should not onTouchTap from when dragging beyond threshold
535 * should listen to events only once
536 * should work with event plugins without dependencies
537 * should work with event plugins with dependencies
@@ -567,6 +568,7 @@ src/renderers/dom/shared/__tests__/ReactDOMComponent-test.js
568 * should generate the correct markup with className
569 * should escape style names and values
570 * should handle dangerouslySetInnerHTML
571 +* should work error event on <source> element
572 * should not duplicate uppercased selfclosing tags
573 * should warn against children for void elements
574 * should warn against dangerouslySetInnerHTML for void elements
@@ -613,6 +615,10 @@ src/renderers/dom/shared/__tests__/ReactDOMTextComponent-test.js
615 * can be toggled in and out of the markup
616 * can reconcile text from pre-rendered markup
617
618 +src/renderers/dom/shared/__tests__/ReactEventIndependence-test.js
619 +* does not crash with other react inside
620 +* does not crash with other react outside
621 +
622 src/renderers/dom/shared/__tests__/ReactEventListener-test.js
623 * should dispatch events from outside React tree
624 * should propagate events one level down
@@ -638,6 +644,7 @@ src/renderers/dom/shared/__tests__/inputValueTracking-test.js
644 * should update value if it changed and return result
645 * should track value and return true when updating untracked instance
646 * should return tracker from node
647 +* should stop tracking
648
649 src/renderers/dom/shared/__tests__/quoteAttributeValueForBrowser-test.js
650 * should escape boolean to string
@@ -655,8 +662,14 @@ src/renderers/dom/shared/eventPlugins/__tests__/BeforeInputEventPlugin-test.js
662 * extract onBeforeInput from fallback objects
663
664 src/renderers/dom/shared/eventPlugins/__tests__/ChangeEventPlugin-test.js
665 +* should fire change for checkbox input
666 * should catch setting the value programmatically
667 +* should not fire change when setting the value programmatically
668 * should unmount
669 +* should only fire change for checked radio button once
670 +* should deduplicate input value change events
671 +* should listen for both change and input events when supported
672 +* should only fire events when the value changes for range inputs
673
674 src/renderers/dom/shared/eventPlugins/__tests__/EnterLeaveEventPlugin-test.js
675 * should set relatedTarget properly in iframe
@@ -670,7 +683,24 @@ src/renderers/dom/shared/eventPlugins/__tests__/FallbackCompositionState-test.js
683 * extracts when inserted within text
684 * extracts when inserted at end of text
685
686 +src/renderers/dom/shared/eventPlugins/__tests__/SelectEventPlugin-test.js
687 +* should skip extraction if no listeners are present
688 +* should extract if an `onSelect` listener is present
689 +
690 src/renderers/dom/shared/eventPlugins/__tests__/SimpleEventPlugin-test.js
691 +* A non-interactive tags click when disabled
692 +* should forward clicks when it starts out not disabled
693 +* should forward clicks when it becomes not disabled
694 +* should work correctly if the listener is changed
695 +* should forward clicks when it starts out not disabled
696 +* should forward clicks when it becomes not disabled
697 +* should work correctly if the listener is changed
698 +* should forward clicks when it starts out not disabled
699 +* should forward clicks when it becomes not disabled
700 +* should work correctly if the listener is changed
701 +* should forward clicks when it starts out not disabled
702 +* should forward clicks when it becomes not disabled
703 +* should work correctly if the listener is changed
704 * does not add a local click to interactive elements
705 * adds a local click listener to non-interactive elements
706
@@ -738,6 +768,9 @@ src/renderers/dom/shared/utils/__tests__/getNodeForCharacterOffset-test.js
768 src/renderers/dom/shared/utils/__tests__/setInnerHTML-test.js
769 * sets innerHTML on it
770
771 +src/renderers/dom/shared/wrappers/__tests__/ReactDOMIframe-test.js
772 +* should trigger load events
773 +
774 src/renderers/dom/shared/wrappers/__tests__/ReactDOMInput-test.js
775 * should properly control a value even if no event listener exists
776 * should control values in reentrant events with different targets
@@ -745,6 +778,8 @@ src/renderers/dom/shared/wrappers/__tests__/ReactDOMInput-test.js
778 * only assigns defaultValue if it changes
779 * should display "true" for `defaultValue` of `true`
780 * should display "false" for `defaultValue` of `false`
781 +* should update `defaultValue` for uncontrolled input
782 +* should update `defaultValue` for uncontrolled date/time input
783 * should take `defaultValue` when changing to uncontrolled input
784 * should render defaultValue for SSR
785 * should render value for SSR
@@ -759,23 +794,36 @@ src/renderers/dom/shared/wrappers/__tests__/ReactDOMInput-test.js
794 * should allow setting `value` to `objToString`
795 * should not incur unnecessary DOM mutations
796 * should properly control a value of number `0`
797 +* should have the correct target value
798 * should not set a value for submit buttons unnecessarily
799 * should control radio buttons
800 * should control radio buttons if the tree updates during render
801 * should warn with value and no onChange handler and readOnly specified
802 * should have a this value of undefined if bind is not used
803 * should warn with checked and no onChange handler with readOnly specified
804 +* should update defaultValue to empty string
805 * should warn if checked and defaultChecked props are specified
806 * should warn if value and defaultValue props are specified
807 +* should warn if controlled input switches to uncontrolled (value is undefined)
808 +* should warn if controlled input switches to uncontrolled with defaultValue
809 * should warn if uncontrolled input (value is undefined) switches to controlled
810 +* should warn if controlled checkbox switches to uncontrolled (checked is undefined)
811 +* should warn if controlled checkbox switches to uncontrolled (checked is null)
812 +* should warn if controlled checkbox switches to uncontrolled with defaultChecked
813 * should warn if uncontrolled checkbox (checked is undefined) switches to controlled
814 * should warn if uncontrolled checkbox (checked is null) switches to controlled
815 +* should warn if controlled radio switches to uncontrolled (checked is undefined)
816 +* should warn if controlled radio switches to uncontrolled (checked is null)
817 +* should warn if controlled radio switches to uncontrolled with defaultChecked
818 * should warn if uncontrolled radio (checked is undefined) switches to controlled
819 * should warn if uncontrolled radio (checked is null) switches to controlled
820 * should not warn if radio value changes but never becomes controlled
821 * should not warn if radio value changes but never becomes uncontrolled
822 +* should warn if radio checked false changes to become uncontrolled
823 +* sets type, step, min, max before value always
824 * sets value properly with type coming later in props
825 * does not raise a validation warning when it switches types
826 +* resets value of date/time input to fix bugs in iOS Safari
827
828 src/renderers/dom/shared/wrappers/__tests__/ReactDOMOption-test.js
829 * should flatten children to a string
@@ -787,6 +835,8 @@ src/renderers/dom/shared/wrappers/__tests__/ReactDOMOption-test.js
835 src/renderers/dom/shared/wrappers/__tests__/ReactDOMSelect-test.js
836 * should not throw with `defaultValue` and without children
837 * should not throw with `value` and without children
838 +* should reset child options selected when they are changed and `value` is set
839 +* should remember updated value when switching to uncontrolled
840 * should support server-side rendering
841 * should support server-side rendering with defaultValue
842 * should support server-side rendering with multiple
@@ -799,15 +849,23 @@ src/renderers/dom/shared/wrappers/__tests__/ReactDOMTextarea-test.js
849 * should display `defaultValue` of number 0
850 * should display "false" for `defaultValue` of `false`
851 * should display "foobar" for `defaultValue` of `objToString`
852 +* should set defaultValue
853 * should not render value as an attribute
854 * should display `value` of number 0
855 +* should update defaultValue to empty string
856 +* should allow setting `value` to `giraffe`
857 * should render defaultValue for SSR
858 * should render value for SSR
859 +* should allow setting `value` to `true`
860 +* should allow setting `value` to `false`
861 +* should allow setting `value` to `objToString`
862 * should take updates to `defaultValue` for uncontrolled textarea
863 * should take updates to children in lieu of `defaultValue` for uncontrolled textarea
864 +* should not incur unnecessary DOM mutations
865 * should properly control a value of number `0`
866 * should treat children like `defaultValue`
867 * should keep value when switching to uncontrolled element if not changed
868 +* should keep value when switching to uncontrolled element if changed
869 * should allow numbers as children
870 * should allow booleans as children
871 * should allow objects as children
@@ -1090,6 +1148,7 @@ src/renderers/shared/shared/__tests__/ReactTreeTraversal-test.js
1148
1149 src/renderers/shared/shared/event/__tests__/EventPluginHub-test.js
1150 * should prevent non-function listeners, at dispatch
1151 +* should not prevent null listeners, at dispatch
1152
1153 src/renderers/shared/shared/event/__tests__/EventPluginRegistry-test.js
1154 * should be able to inject ordering before plugins
src/renderers/dom/shared/__tests__/ReactBrowserEventEmitter-test.js
+3 -3
@@ -496,9 +496,9 @@ describe('ReactBrowserEventEmitter', () => {
496 ReactTestUtils.nativeTouchData(0, 0)
497 );
498 expect(idCallOrder.length).toBe(3);
499 - expect(idCallOrder[0]).toBe(CHILD);
500 - expect(idCallOrder[1]).toBe(PARENT);
501 - expect(idCallOrder[2]).toBe(GRANDPARENT);
499 + expect(idCallOrder[0] === CHILD).toBe(true);
500 + expect(idCallOrder[1] === PARENT).toBe(true);
501 + expect(idCallOrder[2] === GRANDPARENT).toBe(true);
502 });
503
504 it('should not crash ensureScrollValueMonitoring when createEvent returns null', () => {