react-styled-select
react-styled-select copied to clipboard
Trying to test it with react-test-renderer does not work
Just importing the component gives error:
ReferenceError: MutationObserver is not defined
at Object.<anonymous> (node_modules/@webcomponents/shadydom/shadydom.min.js:16:377)
at Object.<anonymous> (node_modules/@webcomponents/shadydom/shadydom.min.js:66:338)
at Object.<anonymous>.Object.defineProperty.value (node_modules/react-styled-select/lib/Select/Select.js:5:986)
at Object.<anonymous> (node_modules/react-styled-select/lib/Select/Select.js:13:3)
at Object.<anonymous>.Object.defineProperty.value (node_modules/react-styled-select/lib/index.js:5:40)
at Object.<anonymous> (node_modules/react-styled-select/lib/index.js:13:3)
at Object.<anonymous> (src/components/common/select/select.js:2:26)
at Object.<anonymous> (src/__tests__/select.test.js:5:15)
at Generator.next (<anonymous>)
at Promise (<anonymous>)
at Generator.next (<anonymous>)
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:188:7)
Having this same problem. Any progress on this?
BTW: Quick solve was to downgrade the version (for anyone coming across this open issue).
Hi, sorry about that, I will see it as soon as possible!
@vladejs @iansolano I have not any info about how can I reproduce this problem, but I did some research about this error and I did some fixes, can you test it please?
If still have the problem, can you say what test engine are you using (Jest or mocha or karma)? React Versions etc?
Tks
new version 2.2.5-beta
@agutoli just tested, still the same error. Using Jest "jest": "20.0.4"
and "react": "^16.2.0"
. Also tested with the latest stable release of jest 22.3.0
and received the same MutationObserver
error.
The 2.1.2-alpha
release works fine with my current configuration. Hopefully that helps. Thanks for following up.
@iansolano I just did a new fix, can you try it please? tks
new version 2.2.6-beta
@agutoli sorry about the delay. Still failing:
This is the install from 2.1.2-alpha
:
I wonder if the version of react-shadow
is a problem here? I don't know. Sorry, ATM I don't really have the time to look into this and help out. If I find some free time I'll try to take a look. Hopefully this helps.