From 573db0d466bfbf2152d2558c835b34ac81a13956 Mon Sep 17 00:00:00 2001 From: Mike Turley Date: Tue, 25 Sep 2018 09:23:54 -0400 Subject: [PATCH] Fix broken test --- .../App/Overview/__test__/__snapshots__/index.test.js.snap | 2 ++ .../App/Overview/components/EditPlanNameModal/index.js | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/app/javascript/react/screens/App/Overview/__test__/__snapshots__/index.test.js.snap b/app/javascript/react/screens/App/Overview/__test__/__snapshots__/index.test.js.snap index 90821cc554..463ca77384 100644 --- a/app/javascript/react/screens/App/Overview/__test__/__snapshots__/index.test.js.snap +++ b/app/javascript/react/screens/App/Overview/__test__/__snapshots__/index.test.js.snap @@ -32,6 +32,7 @@ Object { "finishedWithErrorTransformationPlans": Array [], "hideConfirmModalAction": [Function], "hideDeleteConfirmationModalAction": [Function], + "hideEditPlanNameModalAction": [Function], "hideMappingWizard": false, "hidePlanWizard": false, "isFetchingArchivedTransformationPlans": "true", @@ -59,6 +60,7 @@ Object { "setMigrationsFilterAction": [Function], "showConfirmModalAction": [Function], "showDeleteConfirmationModalAction": [Function], + "showEditPlanNameModalAction": [Function], "showMappingWizardAction": [Function], "showMappingWizardEditModeAction": [Function], "showPlanWizardAction": [Function], diff --git a/app/javascript/react/screens/App/Overview/components/EditPlanNameModal/index.js b/app/javascript/react/screens/App/Overview/components/EditPlanNameModal/index.js index a070a8676a..ff7a159311 100644 --- a/app/javascript/react/screens/App/Overview/components/EditPlanNameModal/index.js +++ b/app/javascript/react/screens/App/Overview/components/EditPlanNameModal/index.js @@ -7,12 +7,12 @@ import reducer from './EditPlanNameReducer'; export const reducers = { editPlanName: reducer }; -const mapStateToProps = ({ editPlanName, overview, form: { editPlanNameModal } }) => { +const mapStateToProps = ({ editPlanName, overview, form }) => { const plans = [...overview.transformationPlans, ...overview.archivedTransformationPlans]; const editingPlan = findEditingPlan(plans, overview.editingPlanId); return { ...editPlanName, - editPlanNameModal, + editPlanNameModal: form && form.editPlanNameModal, initialValues: { name: editingPlan ? editingPlan.name : '', description: editingPlan ? editingPlan.description : ''