Bug 43283 - Save action should add extension .jmx if not present
Summary: Save action should add extension .jmx if not present
Alias: None
Product: JMeter
Classification: Unclassified
Component: HTTP (show other bugs)
Version: 2.2
Hardware: All All
: P2 enhancement (vote)
Target Milestone: ---
Assignee: JMeter issues mailing list
Depends on:
Reported: 2007-09-02 04:16 UTC by Alf Hogemark
Modified: 2007-09-02 05:46 UTC (History)
0 users

Suggested patch (3.68 KB, patch)
2007-09-02 04:18 UTC, Alf Hogemark
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alf Hogemark 2007-09-02 04:16:11 UTC
I think the Save action in JMeter should add the ".jmx" file extension if the
user forgets to enter it when entering the file name.
If the user forgets to do so, he will not be able to load the file back in, but
has to change the name of the file first, to have the .jmx extension.

I also think the save action should prompt before overwriting an existing file,
when the user does a "save as".
Comment 1 Alf Hogemark 2007-09-02 04:18:22 UTC
Created attachment 20753 [details]
Suggested patch

The dialog when overwriting a file is optional, but I think the adding of the
jmx extension should be done.

Also, other code should probably be changed to use a string constant instead of
Comment 2 Sebb 2007-09-02 05:06:10 UTC
Good idea, but I think the extension should only be added if there is none.

It can be useful to save a copy of a file with a different extension - e.g. 
for use in the include controller.

I'll change the check accordingly.
Comment 3 Sebb 2007-09-02 05:46:09 UTC
Added to SVN in r571968.

I'll raise another bug regarding centralisation of .jmx, .jtl etc strings.