Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

305
Views
Error de broma: violación invariable no detectada: se detectó una mutación de estado entre despachos, en la ruta

Estoy tratando de ejecutar una prueba de broma existente después de que hice un cambio momentTimezone en el código. Creo que es porque mi cambio hace otro cambio de estado entre el despacho redux en el caso de prueba. No estoy seguro de cómo solucionarlo. El valor esperado es citaGroupState.isBookingLocked es falso en lugar de verdadero junto con este error: a continuación se muestra el código de broma donde se genera el error:

No detectado [Violación invariable: se detectó una mutación de estado entre envíos, en la ruta suggestionSearchCriteria.beginDate._locale._longDateFormat.l .

 const recurViewPresenterComponentState = wrapper .find('RecurViewPresenter') .prop('recurViewPresenterComponentState'); const appointmentGroupState = recurViewPresenterComponentState.recurUIAppointmentGroupStates.find( ({ id }) => id === MockRecurUIComponentConfigurationMultipleApptGroups.appointmentGroups[0].uuid, ); **expect(appointmentGroupState.isBookingLocked).toBe(true);** });

Aquí está mi fragmento de código principal: momentTimezone (patientDurationDisplay.beginDateTime); Acabo de agregar momentTimezone y la broma está fallando.

Aquí está el envío completo

 const clickAppointmentTypeCard = (wrapper, apptTypeCardIndex) => { wrapper.find('.single-appointment-type-card-list > *').at(apptTypeCardIndex).simulate('click'); }; let wrapper; window.featureToggles = { getAllEnabledToggles: () => [], }; beforeEach(() => { wrapper = mountWithTestFileI18N( <RecurViewPresenter recurUIComponentConfiguration={ new RecurUIComponentConfiguration({ ...MockRecurUIComponentConfigurationMultipleApptGroups, appointmentGroups: [ { ...MockRecurUIComponentConfigurationMultipleApptGroups.appointmentGroups[0], appointmentGroupConfiguration: { ...MockRecurUIComponentConfigurationMultipleApptGroups.appointmentGroups[0] .appointmentGroupConfiguration, multipleAppointmentInstancesConfiguration: { numberOfAppointmentInstancesInADay: 1, hoursBetweenAppointmentInstancesInADay: 0, }, }, }, MockRecurUIComponentConfigurationMultipleApptGroups.appointmentGroups[1], ], }) } retrieveRecurringAppointmentSuggestions={() => createMockAppointmentGroupSuggestionResult()} onSuggestionsSelected={() => ({ bookingStatus: 'SUCCESS', lockReleaseStatus: 'SUCCESS', })} />, ); afterEach(() => { mockSuggestionResultsComponentSelection = { ...mockSuggestionResultsComponentSelection, instanceIndex: 1, }; }); ```
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!