diff --git a/client/src/plugins/camunda-plugin/deployment-tool/DeploymentConfigModal.js b/client/src/plugins/camunda-plugin/deployment-tool/DeploymentConfigModal.js
index ab160e21b..1c98e42a5 100644
--- a/client/src/plugins/camunda-plugin/deployment-tool/DeploymentConfigModal.js
+++ b/client/src/plugins/camunda-plugin/deployment-tool/DeploymentConfigModal.js
@@ -335,7 +335,7 @@ export default class DeploymentConfigModal extends React.PureComponent {
diff --git a/client/src/plugins/camunda-plugin/deployment-tool/__tests__/DeploymentConfigModalSpec.js b/client/src/plugins/camunda-plugin/deployment-tool/__tests__/DeploymentConfigModalSpec.js
index 0e48207ec..ec1910470 100644
--- a/client/src/plugins/camunda-plugin/deployment-tool/__tests__/DeploymentConfigModalSpec.js
+++ b/client/src/plugins/camunda-plugin/deployment-tool/__tests__/DeploymentConfigModalSpec.js
@@ -161,8 +161,72 @@ describe('', () => {
expect(wrapper.find('.hint.error')).to.have.length(1);
});
+
+ it('should disable deploy button when connection cannot be established', async () => {
+
+ // given
+ const configuration = {
+ deployment: {
+ tenantId: '',
+ name: 'diagram'
+ },
+ endpoint: {
+ url: 'http://localhost:8088/engine-rest',
+ authType: AuthTypes.none
+ }
+ };
+
+ const connectionChecker = new MockConnectionChecker();
+
+ const {
+ wrapper
+ } = createModal({
+ connectionChecker,
+ configuration
+ }, mount);
+
+ // when
+ await connectionChecker.triggerComplete({ connectionError: true });
+
+ wrapper.update();
+
+ // then
+ expect(wrapper.find('.btn-primary').props()).to.have.property('disabled', true);
+ });
});
+
+ it('should disable deploy button when form is invalid', async () => {
+
+ // given
+ const configuration = {
+ deployment: {
+ tenantId: '',
+ name: ''
+ },
+ endpoint: {
+ url: 'http://localhost:8088/engine-rest',
+ authType: AuthTypes.none
+ }
+ };
+
+ const connectionChecker = new MockConnectionChecker();
+
+ const {
+ wrapper
+ } = createModal({
+ connectionChecker,
+ configuration
+ }, mount);
+
+ // when
+ await connectionChecker.triggerComplete({});
+
+ wrapper.update();
+
+ // then
+ expect(wrapper.find('.btn-primary').props()).to.have.property('disabled', true);
+ });
});