diff --git a/hailstorm-web-client/Makefile b/hailstorm-web-client/Makefile
index ce9c8e8d..19688509 100644
--- a/hailstorm-web-client/Makefile
+++ b/hailstorm-web-client/Makefile
@@ -55,3 +55,11 @@ validate:
git diff ${TRAVIS_COMMIT_RANGE} -- package.json | grep -e '[+\-].*version' > /dev/null; \
[ $$? -eq 0 ]; \
fi
+
+integration_test_bed_up:
+ cd ../ && docker-compose -f docker-compose.yml -f docker-compose.dc-sim.yml -f docker-compose.web-ci.yml up -d \
+ hailstorm-api hailstorm-agent-1 hailstorm-agent-2 file-server
+
+
+integration_test_bed_down:
+ cd ../ && docker-compose -f docker-compose.yml -f docker-compose.dc-sim.yml -f docker-compose.web-ci.yml down
diff --git a/hailstorm-web-client/src/JMeterConfiguration/ActiveFileDetail.tsx b/hailstorm-web-client/src/JMeterConfiguration/ActiveFileDetail.tsx
index 579616f0..5b8c369e 100644
--- a/hailstorm-web-client/src/JMeterConfiguration/ActiveFileDetail.tsx
+++ b/hailstorm-web-client/src/JMeterConfiguration/ActiveFileDetail.tsx
@@ -17,7 +17,7 @@ export function ActiveFileDetail({ state, dispatch, setShowModal, setUploadAbort
const onSubmit: FormikActionsHandler = (
values,
- { setSubmitting }
+ { setSubmitting, resetForm }
) => {
setSubmitting(true);
const promise = state.wizardState!.activeJMeterFile!.id === undefined ?
@@ -38,6 +38,7 @@ export function ActiveFileDetail({ state, dispatch, setShowModal, setUploadAbort
dispatch(new MergeJMeterFileAction(jmeterFile));
})
.catch((reason) => console.error(reason))
+ .then(() => resetForm(values))
.then(() => setSubmitting(false));
};
diff --git a/hailstorm-web-client/src/JMeterConfiguration/JMeterConfiguration.test.tsx b/hailstorm-web-client/src/JMeterConfiguration/JMeterConfiguration.test.tsx
index 0c475d48..70f5efe6 100644
--- a/hailstorm-web-client/src/JMeterConfiguration/JMeterConfiguration.test.tsx
+++ b/hailstorm-web-client/src/JMeterConfiguration/JMeterConfiguration.test.tsx
@@ -62,7 +62,7 @@ describe('', () => {
)
}
- function mockFile(name: string): File {
+ function mockFile(name: string): {[K in keyof File]?: File[K]} {
return {
name,
type: 'text/xml',
@@ -114,7 +114,7 @@ describe('', () => {
it('should indicate that file upload has started', () => {
const component = mount(createComponent());
const onAccept = component.find('FileUpload').prop('onAccept') as ((file: File) => void);
- onAccept(mockFile("a"));
+ onAccept(mockFile("a") as File);
expect(dispatch).toHaveBeenCalled();
appState.wizardState!.activeJMeterFile = {
name: 'a.jmx',
@@ -183,7 +183,7 @@ describe('', () => {
const component = mount(createComponent());
const onUploadError = component.find('FileUpload').prop('onUploadError') as ((file: File, error: any) => void);
const error = new Error('Server not available');
- onUploadError(mockFile("a"), error);
+ onUploadError(mockFile("a") as File, error);
appState.wizardState!.activeJMeterFile = {
name: 'a.jmx',
uploadProgress: undefined,
diff --git a/hailstorm-web-client/src/JMeterConfiguration/JMeterPropertiesMap.tsx b/hailstorm-web-client/src/JMeterConfiguration/JMeterPropertiesMap.tsx
index eba5e4a6..2f5fb21c 100644
--- a/hailstorm-web-client/src/JMeterConfiguration/JMeterPropertiesMap.tsx
+++ b/hailstorm-web-client/src/JMeterConfiguration/JMeterPropertiesMap.tsx
@@ -122,7 +122,7 @@ function PropertiesForm({
- {({isSubmitting, isValid}) => (
+ {({isSubmitting, isValid, dirty}) => (