You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jmeter.apache.org by sebb <se...@gmail.com> on 2013/07/09 13:46:22 UTC

New from Template silently overwrites files

Just noticed that the "New From Template" feature creates a file in
the current working directory.

It silently overwrites any file with the same name as the template.

It would be easy to lose a valuable test plan.

I'm not sure why the code does not just load the content from the
template, and leave to the user to save the test plan where they wish.
After all, unless they change the template, they can just refetch it.

Thoughts?

Re: New from Template silently overwrites files

Posted by sebb <se...@gmail.com>.
On 11 July 2013 00:39, Milamber <mi...@apache.org> wrote:
>
> Le 10/07/2013 23:29, sebb a ecrit :
>
>> On 11 July 2013 00:12, Milamber <mi...@apache.org> wrote:
>>>
>>> Hello,
>>>
>>> I've use the new templates's behavior today.
>>>
>>> I have some improvements in my mind (and in better world) ;-)
>>>
>>> * Loading as templates's bundle every file with .xml extension, to allow
>>> any
>>> tiers provider to distribute 'templates pack'
>>
>> I'd had the same idea; thought I'd already sent a message - turns out
>> it was sent to Commons by mistake. I've resent it here, see separate
>> message.
>
>
> Yeah! Same idea!
>
>
>>
>>> * Act as template all jmx files in /bin/templates/ even if the file isn't
>>> in
>>> a template.xml, to allow end user to 'create' across a easy way a
>>> template
>>> from their test plan.
>>
>> Not so sure about that - it would be expensive parsing the file for a
>> template dialog entry - and how is that different from using the Open
>> dialog?
>
>
> Just for simplify the life of end user (and me). Have a single directory to
> put my templates, to reuse it (without any directory navigation like
> Open/Merge dialog box)
>
> Today, in UI design, there are always a lot of ways to do the same thing.
> It's offer more ways to end user.
>

I see.

Not sure it's a good idea to mix indexed non-indexed templates in the
same directory.
The code would need to check whether the files were in the index or
not otherwise they might appear twice.

Maybe have a tabbed panel, one for indexed files and the other for a file list.
These would be in separate directories.
Since the non-indexed files don't have fancy descriptions, maybe a
clickable list would be better than a drop-down.
A bit like how the Apache server shows directory listings.

>
>
>>
>>> I'm not study (in this time) the way to do this. Any opinion? (I'm too
>>> greedy?)
>>>
>>> Milamber
>
>

Re: New from Template silently overwrites files

Posted by Milamber <mi...@apache.org>.
Le 10/07/2013 23:29, sebb a ecrit :
> On 11 July 2013 00:12, Milamber <mi...@apache.org> wrote:
>> Hello,
>>
>> I've use the new templates's behavior today.
>>
>> I have some improvements in my mind (and in better world) ;-)
>>
>> * Loading as templates's bundle every file with .xml extension, to allow any
>> tiers provider to distribute 'templates pack'
> I'd had the same idea; thought I'd already sent a message - turns out
> it was sent to Commons by mistake. I've resent it here, see separate
> message.

Yeah! Same idea!

>
>> * Act as template all jmx files in /bin/templates/ even if the file isn't in
>> a template.xml, to allow end user to 'create' across a easy way a template
>> from their test plan.
> Not so sure about that - it would be expensive parsing the file for a
> template dialog entry - and how is that different from using the Open
> dialog?

Just for simplify the life of end user (and me). Have a single directory 
to put my templates, to reuse it (without any directory navigation like 
Open/Merge dialog box)

Today, in UI design, there are always a lot of ways to do the same 
thing. It's offer more ways to end user.



>
>> I'm not study (in this time) the way to do this. Any opinion? (I'm too
>> greedy?)
>>
>> Milamber


Re: New from Template silently overwrites files

Posted by sebb <se...@gmail.com>.
On 11 July 2013 00:12, Milamber <mi...@apache.org> wrote:
> Hello,
>
> I've use the new templates's behavior today.
>
> I have some improvements in my mind (and in better world) ;-)
>
> * Loading as templates's bundle every file with .xml extension, to allow any
> tiers provider to distribute 'templates pack'

I'd had the same idea; thought I'd already sent a message - turns out
it was sent to Commons by mistake. I've resent it here, see separate
message.

> * Act as template all jmx files in /bin/templates/ even if the file isn't in
> a template.xml, to allow end user to 'create' across a easy way a template
> from their test plan.

Not so sure about that - it would be expensive parsing the file for a
template dialog entry - and how is that different from using the Open
dialog?

> I'm not study (in this time) the way to do this. Any opinion? (I'm too
> greedy?)
>
> Milamber

Re: New from Template silently overwrites files

Posted by Milamber <mi...@apache.org>.
Hello,

I've use the new templates's behavior today.

I have some improvements in my mind (and in better world) ;-)

* Loading as templates's bundle every file with .xml extension, to allow 
any tiers provider to distribute 'templates pack'

* Act as template all jmx files in /bin/templates/ even if the file 
isn't in a template.xml, to allow end user to 'create' across a easy way 
a template from their test plan.

I'm not study (in this time) the way to do this. Any opinion? (I'm too 
greedy?)

Milamber



Le 10/07/2013 16:51, Philippe Mouawad a ecrit :
> Hello,
> Thanks for the great work on this done by you 2.
>
> Regards
> Philippe
>
> On Wed, Jul 10, 2013 at 5:20 PM, sebb <se...@gmail.com> wrote:
>
>> On 10 July 2013 14:02, Milamber <mi...@apache.org> wrote:
>>> Le 09/07/2013 22:31, sebb a ecrit :
>>>
>>>> OK, done - I hope!
>>>
>>> Thanks, I made some tests with succes.
>>>
>>>
>>> The templates seems a very good feature to JMeter, bring a lot of new
>>> opportunities.
>>>
>> Yes.
>>
>> I was initially sceptical, but having seen it in use, I can see it is
>> useful for getting started.
>>
>>>
>>>> On 9 July 2013 16:20, Milamber <mi...@apache.org> wrote:
>>>>> Le 09/07/2013 14:58, sebb a ecrit :
>>>>>
>>>>>> On 9 July 2013 14:58, Milamber <mi...@apache.org> wrote:
>>>>>>> Le 09/07/2013 13:20, sebb a ecrit :
>>>>>>>
>>>>>>>> On 9 July 2013 13:01, sebb <se...@gmail.com> wrote:
>>>>>>>>> On 9 July 2013 12:53, Milamber <mi...@apache.org> wrote:
>>>>>>>>>> Le 09/07/2013 11:46, sebb a ecrit :
>>>>>>>>>>
>>>>>>>>>>> Just noticed that the "New From Template" feature creates a file
>> in
>>>>>>>>>>> the current working directory.
>>>>>>>>>>>
>>>>>>>>>>> It silently overwrites any file with the same name as the
>> template.
>>>>>>>>>>> It would be easy to lose a valuable test plan.
>>>>>>>>>>>
>>>>>>>>>>> I'm not sure why the code does not just load the content from the
>>>>>>>>>>> template, and leave to the user to save the test plan where they
>>>>>>>>>>> wish.
>>>>>>>>>>
>>>>>>>>>> +1, I would be better to make like "merge" (or use the merge
>>>>>>>>>> functionalty)
>>>>>>>>>> to open the template.
>>>>>>>>>>
>>>>>>>>> Yes - would need to clear any existing plan first though.
>>>>>>>>>
>>>>>>>> Just occurs to me that one might want to use templates for partial
>>>>>>>> test
>>>>>>>> plans?
>>>>>>>
>>>>>>> Yes, I think it's natural to use the template as partial test plans
>>>>>>> (like
>>>>>>> "add my favorite listener")
>>>>>>>
>>>>>>>
>>>>>>>> If so, then it would be useful not to clear the existing plan first.
>>>>>>>
>>>>>>> Yes. Perhaps a checkbox "Replace (and remove) current test plan" or
>>>>>>> "Merge
>>>>>>> with current test plans".
>>>>>>>
>>>>>> If the template is a comple test plan, I'm not sure it makes sense to
>>>>>> Merge it.
>>>>>> Likewise snippets must be Merged.
>>>>>>
>>>>>> Maybe the "Create" button at the bottom needs to change according to
>>>>>> the template type - either "Create" or "Merge" ?
>>>>>
>>>>> +1 seems the good deal.
>>>>>
>>>>>
>>>>>>>> Maybe the templates.xml file could include a flag to say whether the
>>>>>>>> template was a complete test plan or just a snippet?
>>>>>>>> That would allow the dialog box to easily distinguish the two types.
>>>>>>>
>>>>>>> +1
>>>>>>>
>>>>>>>
>>>>>>>> The Menu item would need to be changed to "Templates..."
>>>>>>>
>>>>>>> Philippe has already do this for french translation ("Modèles..." not
>>>>>>> "Nouveau depuis modèles")
>>>>>>> I agree "Templates..." seems better.
>>>>>>>
>>>>>>>
>>>>>>>>>>> After all, unless they change the template, they can just refetch
>>>>>>>>>>> it.
>>>>>>>>>>>
>>>>>>>>>>> Thoughts?
>>>>>>>>>>>
>
>


Re: New from Template silently overwrites files

Posted by Philippe Mouawad <ph...@gmail.com>.
Hello,
Thanks for the great work on this done by you 2.

Regards
Philippe

On Wed, Jul 10, 2013 at 5:20 PM, sebb <se...@gmail.com> wrote:

> On 10 July 2013 14:02, Milamber <mi...@apache.org> wrote:
> >
> > Le 09/07/2013 22:31, sebb a ecrit :
> >
> >> OK, done - I hope!
> >
> >
> > Thanks, I made some tests with succes.
> >
> >
> > The templates seems a very good feature to JMeter, bring a lot of new
> > opportunities.
> >
>
> Yes.
>
> I was initially sceptical, but having seen it in use, I can see it is
> useful for getting started.
>
> >
> >
> >>
> >> On 9 July 2013 16:20, Milamber <mi...@apache.org> wrote:
> >>>
> >>> Le 09/07/2013 14:58, sebb a ecrit :
> >>>
> >>>> On 9 July 2013 14:58, Milamber <mi...@apache.org> wrote:
> >>>>>
> >>>>> Le 09/07/2013 13:20, sebb a ecrit :
> >>>>>
> >>>>>> On 9 July 2013 13:01, sebb <se...@gmail.com> wrote:
> >>>>>>>
> >>>>>>> On 9 July 2013 12:53, Milamber <mi...@apache.org> wrote:
> >>>>>>>>
> >>>>>>>> Le 09/07/2013 11:46, sebb a ecrit :
> >>>>>>>>
> >>>>>>>>> Just noticed that the "New From Template" feature creates a file
> in
> >>>>>>>>> the current working directory.
> >>>>>>>>>
> >>>>>>>>> It silently overwrites any file with the same name as the
> template.
> >>>>>>>>>
> >>>>>>>>> It would be easy to lose a valuable test plan.
> >>>>>>>>>
> >>>>>>>>> I'm not sure why the code does not just load the content from the
> >>>>>>>>> template, and leave to the user to save the test plan where they
> >>>>>>>>> wish.
> >>>>>>>>
> >>>>>>>>
> >>>>>>>> +1, I would be better to make like "merge" (or use the merge
> >>>>>>>> functionalty)
> >>>>>>>> to open the template.
> >>>>>>>>
> >>>>>>> Yes - would need to clear any existing plan first though.
> >>>>>>>
> >>>>>> Just occurs to me that one might want to use templates for partial
> >>>>>> test
> >>>>>> plans?
> >>>>>
> >>>>>
> >>>>> Yes, I think it's natural to use the template as partial test plans
> >>>>> (like
> >>>>> "add my favorite listener")
> >>>>>
> >>>>>
> >>>>>> If so, then it would be useful not to clear the existing plan first.
> >>>>>
> >>>>>
> >>>>> Yes. Perhaps a checkbox "Replace (and remove) current test plan" or
> >>>>> "Merge
> >>>>> with current test plans".
> >>>>>
> >>>> If the template is a comple test plan, I'm not sure it makes sense to
> >>>> Merge it.
> >>>> Likewise snippets must be Merged.
> >>>>
> >>>> Maybe the "Create" button at the bottom needs to change according to
> >>>> the template type - either "Create" or "Merge" ?
> >>>
> >>>
> >>> +1 seems the good deal.
> >>>
> >>>
> >>>>>> Maybe the templates.xml file could include a flag to say whether the
> >>>>>> template was a complete test plan or just a snippet?
> >>>>>> That would allow the dialog box to easily distinguish the two types.
> >>>>>
> >>>>>
> >>>>> +1
> >>>>>
> >>>>>
> >>>>>> The Menu item would need to be changed to "Templates..."
> >>>>>
> >>>>>
> >>>>> Philippe has already do this for french translation ("Modèles..." not
> >>>>> "Nouveau depuis modèles")
> >>>>> I agree "Templates..." seems better.
> >>>>>
> >>>>>
> >>>>>>>>> After all, unless they change the template, they can just refetch
> >>>>>>>>> it.
> >>>>>>>>>
> >>>>>>>>> Thoughts?
> >>>>>>>>>
> >
>



-- 
Cordialement.
Philippe Mouawad.

Re: New from Template silently overwrites files

Posted by sebb <se...@gmail.com>.
On 10 July 2013 14:02, Milamber <mi...@apache.org> wrote:
>
> Le 09/07/2013 22:31, sebb a ecrit :
>
>> OK, done - I hope!
>
>
> Thanks, I made some tests with succes.
>
>
> The templates seems a very good feature to JMeter, bring a lot of new
> opportunities.
>

Yes.

I was initially sceptical, but having seen it in use, I can see it is
useful for getting started.

>
>
>>
>> On 9 July 2013 16:20, Milamber <mi...@apache.org> wrote:
>>>
>>> Le 09/07/2013 14:58, sebb a ecrit :
>>>
>>>> On 9 July 2013 14:58, Milamber <mi...@apache.org> wrote:
>>>>>
>>>>> Le 09/07/2013 13:20, sebb a ecrit :
>>>>>
>>>>>> On 9 July 2013 13:01, sebb <se...@gmail.com> wrote:
>>>>>>>
>>>>>>> On 9 July 2013 12:53, Milamber <mi...@apache.org> wrote:
>>>>>>>>
>>>>>>>> Le 09/07/2013 11:46, sebb a ecrit :
>>>>>>>>
>>>>>>>>> Just noticed that the "New From Template" feature creates a file in
>>>>>>>>> the current working directory.
>>>>>>>>>
>>>>>>>>> It silently overwrites any file with the same name as the template.
>>>>>>>>>
>>>>>>>>> It would be easy to lose a valuable test plan.
>>>>>>>>>
>>>>>>>>> I'm not sure why the code does not just load the content from the
>>>>>>>>> template, and leave to the user to save the test plan where they
>>>>>>>>> wish.
>>>>>>>>
>>>>>>>>
>>>>>>>> +1, I would be better to make like "merge" (or use the merge
>>>>>>>> functionalty)
>>>>>>>> to open the template.
>>>>>>>>
>>>>>>> Yes - would need to clear any existing plan first though.
>>>>>>>
>>>>>> Just occurs to me that one might want to use templates for partial
>>>>>> test
>>>>>> plans?
>>>>>
>>>>>
>>>>> Yes, I think it's natural to use the template as partial test plans
>>>>> (like
>>>>> "add my favorite listener")
>>>>>
>>>>>
>>>>>> If so, then it would be useful not to clear the existing plan first.
>>>>>
>>>>>
>>>>> Yes. Perhaps a checkbox "Replace (and remove) current test plan" or
>>>>> "Merge
>>>>> with current test plans".
>>>>>
>>>> If the template is a comple test plan, I'm not sure it makes sense to
>>>> Merge it.
>>>> Likewise snippets must be Merged.
>>>>
>>>> Maybe the "Create" button at the bottom needs to change according to
>>>> the template type - either "Create" or "Merge" ?
>>>
>>>
>>> +1 seems the good deal.
>>>
>>>
>>>>>> Maybe the templates.xml file could include a flag to say whether the
>>>>>> template was a complete test plan or just a snippet?
>>>>>> That would allow the dialog box to easily distinguish the two types.
>>>>>
>>>>>
>>>>> +1
>>>>>
>>>>>
>>>>>> The Menu item would need to be changed to "Templates..."
>>>>>
>>>>>
>>>>> Philippe has already do this for french translation ("Modèles..." not
>>>>> "Nouveau depuis modèles")
>>>>> I agree "Templates..." seems better.
>>>>>
>>>>>
>>>>>>>>> After all, unless they change the template, they can just refetch
>>>>>>>>> it.
>>>>>>>>>
>>>>>>>>> Thoughts?
>>>>>>>>>
>

Re: New from Template silently overwrites files

Posted by Milamber <mi...@apache.org>.
Le 09/07/2013 22:31, sebb a ecrit :
> OK, done - I hope!

Thanks, I made some tests with succes.


The templates seems a very good feature to JMeter, bring a lot of new 
opportunities.



>
> On 9 July 2013 16:20, Milamber <mi...@apache.org> wrote:
>> Le 09/07/2013 14:58, sebb a ecrit :
>>
>>> On 9 July 2013 14:58, Milamber <mi...@apache.org> wrote:
>>>> Le 09/07/2013 13:20, sebb a ecrit :
>>>>
>>>>> On 9 July 2013 13:01, sebb <se...@gmail.com> wrote:
>>>>>> On 9 July 2013 12:53, Milamber <mi...@apache.org> wrote:
>>>>>>> Le 09/07/2013 11:46, sebb a ecrit :
>>>>>>>
>>>>>>>> Just noticed that the "New From Template" feature creates a file in
>>>>>>>> the current working directory.
>>>>>>>>
>>>>>>>> It silently overwrites any file with the same name as the template.
>>>>>>>>
>>>>>>>> It would be easy to lose a valuable test plan.
>>>>>>>>
>>>>>>>> I'm not sure why the code does not just load the content from the
>>>>>>>> template, and leave to the user to save the test plan where they
>>>>>>>> wish.
>>>>>>>
>>>>>>> +1, I would be better to make like "merge" (or use the merge
>>>>>>> functionalty)
>>>>>>> to open the template.
>>>>>>>
>>>>>> Yes - would need to clear any existing plan first though.
>>>>>>
>>>>> Just occurs to me that one might want to use templates for partial test
>>>>> plans?
>>>>
>>>> Yes, I think it's natural to use the template as partial test plans (like
>>>> "add my favorite listener")
>>>>
>>>>
>>>>> If so, then it would be useful not to clear the existing plan first.
>>>>
>>>> Yes. Perhaps a checkbox "Replace (and remove) current test plan" or
>>>> "Merge
>>>> with current test plans".
>>>>
>>> If the template is a comple test plan, I'm not sure it makes sense to
>>> Merge it.
>>> Likewise snippets must be Merged.
>>>
>>> Maybe the "Create" button at the bottom needs to change according to
>>> the template type - either "Create" or "Merge" ?
>>
>> +1 seems the good deal.
>>
>>
>>>>> Maybe the templates.xml file could include a flag to say whether the
>>>>> template was a complete test plan or just a snippet?
>>>>> That would allow the dialog box to easily distinguish the two types.
>>>>
>>>> +1
>>>>
>>>>
>>>>> The Menu item would need to be changed to "Templates..."
>>>>
>>>> Philippe has already do this for french translation ("Modèles..." not
>>>> "Nouveau depuis modèles")
>>>> I agree "Templates..." seems better.
>>>>
>>>>
>>>>>>>> After all, unless they change the template, they can just refetch it.
>>>>>>>>
>>>>>>>> Thoughts?
>>>>>>>>


Re: New from Template silently overwrites files

Posted by sebb <se...@gmail.com>.
OK, done - I hope!

On 9 July 2013 16:20, Milamber <mi...@apache.org> wrote:
>
> Le 09/07/2013 14:58, sebb a ecrit :
>
>> On 9 July 2013 14:58, Milamber <mi...@apache.org> wrote:
>>>
>>> Le 09/07/2013 13:20, sebb a ecrit :
>>>
>>>> On 9 July 2013 13:01, sebb <se...@gmail.com> wrote:
>>>>>
>>>>> On 9 July 2013 12:53, Milamber <mi...@apache.org> wrote:
>>>>>>
>>>>>> Le 09/07/2013 11:46, sebb a ecrit :
>>>>>>
>>>>>>> Just noticed that the "New From Template" feature creates a file in
>>>>>>> the current working directory.
>>>>>>>
>>>>>>> It silently overwrites any file with the same name as the template.
>>>>>>>
>>>>>>> It would be easy to lose a valuable test plan.
>>>>>>>
>>>>>>> I'm not sure why the code does not just load the content from the
>>>>>>> template, and leave to the user to save the test plan where they
>>>>>>> wish.
>>>>>>
>>>>>>
>>>>>> +1, I would be better to make like "merge" (or use the merge
>>>>>> functionalty)
>>>>>> to open the template.
>>>>>>
>>>>> Yes - would need to clear any existing plan first though.
>>>>>
>>>> Just occurs to me that one might want to use templates for partial test
>>>> plans?
>>>
>>>
>>> Yes, I think it's natural to use the template as partial test plans (like
>>> "add my favorite listener")
>>>
>>>
>>>> If so, then it would be useful not to clear the existing plan first.
>>>
>>>
>>> Yes. Perhaps a checkbox "Replace (and remove) current test plan" or
>>> "Merge
>>> with current test plans".
>>>
>> If the template is a comple test plan, I'm not sure it makes sense to
>> Merge it.
>> Likewise snippets must be Merged.
>>
>> Maybe the "Create" button at the bottom needs to change according to
>> the template type - either "Create" or "Merge" ?
>
>
> +1 seems the good deal.
>
>
>>
>>>> Maybe the templates.xml file could include a flag to say whether the
>>>> template was a complete test plan or just a snippet?
>>>> That would allow the dialog box to easily distinguish the two types.
>>>
>>>
>>> +1
>>>
>>>
>>>> The Menu item would need to be changed to "Templates..."
>>>
>>>
>>> Philippe has already do this for french translation ("Modèles..." not
>>> "Nouveau depuis modèles")
>>> I agree "Templates..." seems better.
>>>
>>>
>>>>>>> After all, unless they change the template, they can just refetch it.
>>>>>>>
>>>>>>> Thoughts?
>>>>>>>
>

Re: New from Template silently overwrites files

Posted by Milamber <mi...@apache.org>.
Le 09/07/2013 14:58, sebb a ecrit :
> On 9 July 2013 14:58, Milamber <mi...@apache.org> wrote:
>> Le 09/07/2013 13:20, sebb a ecrit :
>>
>>> On 9 July 2013 13:01, sebb <se...@gmail.com> wrote:
>>>> On 9 July 2013 12:53, Milamber <mi...@apache.org> wrote:
>>>>> Le 09/07/2013 11:46, sebb a ecrit :
>>>>>
>>>>>> Just noticed that the "New From Template" feature creates a file in
>>>>>> the current working directory.
>>>>>>
>>>>>> It silently overwrites any file with the same name as the template.
>>>>>>
>>>>>> It would be easy to lose a valuable test plan.
>>>>>>
>>>>>> I'm not sure why the code does not just load the content from the
>>>>>> template, and leave to the user to save the test plan where they wish.
>>>>>
>>>>> +1, I would be better to make like "merge" (or use the merge
>>>>> functionalty)
>>>>> to open the template.
>>>>>
>>>> Yes - would need to clear any existing plan first though.
>>>>
>>> Just occurs to me that one might want to use templates for partial test
>>> plans?
>>
>> Yes, I think it's natural to use the template as partial test plans (like
>> "add my favorite listener")
>>
>>
>>> If so, then it would be useful not to clear the existing plan first.
>>
>> Yes. Perhaps a checkbox "Replace (and remove) current test plan" or "Merge
>> with current test plans".
>>
> If the template is a comple test plan, I'm not sure it makes sense to Merge it.
> Likewise snippets must be Merged.
>
> Maybe the "Create" button at the bottom needs to change according to
> the template type - either "Create" or "Merge" ?

+1 seems the good deal.

>
>>> Maybe the templates.xml file could include a flag to say whether the
>>> template was a complete test plan or just a snippet?
>>> That would allow the dialog box to easily distinguish the two types.
>>
>> +1
>>
>>
>>> The Menu item would need to be changed to "Templates..."
>>
>> Philippe has already do this for french translation ("Modèles..." not
>> "Nouveau depuis modèles")
>> I agree "Templates..." seems better.
>>
>>
>>>>>> After all, unless they change the template, they can just refetch it.
>>>>>>
>>>>>> Thoughts?
>>>>>>


Re: New from Template silently overwrites files

Posted by sebb <se...@gmail.com>.
On 9 July 2013 14:58, Milamber <mi...@apache.org> wrote:
>
> Le 09/07/2013 13:20, sebb a ecrit :
>
>> On 9 July 2013 13:01, sebb <se...@gmail.com> wrote:
>>>
>>> On 9 July 2013 12:53, Milamber <mi...@apache.org> wrote:
>>>>
>>>> Le 09/07/2013 11:46, sebb a ecrit :
>>>>
>>>>> Just noticed that the "New From Template" feature creates a file in
>>>>> the current working directory.
>>>>>
>>>>> It silently overwrites any file with the same name as the template.
>>>>>
>>>>> It would be easy to lose a valuable test plan.
>>>>>
>>>>> I'm not sure why the code does not just load the content from the
>>>>> template, and leave to the user to save the test plan where they wish.
>>>>
>>>>
>>>> +1, I would be better to make like "merge" (or use the merge
>>>> functionalty)
>>>> to open the template.
>>>>
>>> Yes - would need to clear any existing plan first though.
>>>
>> Just occurs to me that one might want to use templates for partial test
>> plans?
>
>
> Yes, I think it's natural to use the template as partial test plans (like
> "add my favorite listener")
>
>
>>
>> If so, then it would be useful not to clear the existing plan first.
>
>
> Yes. Perhaps a checkbox "Replace (and remove) current test plan" or "Merge
> with current test plans".
>

If the template is a comple test plan, I'm not sure it makes sense to Merge it.
Likewise snippets must be Merged.

Maybe the "Create" button at the bottom needs to change according to
the template type - either "Create" or "Merge" ?

>>
>> Maybe the templates.xml file could include a flag to say whether the
>> template was a complete test plan or just a snippet?
>> That would allow the dialog box to easily distinguish the two types.
>
>
> +1
>
>
>>
>> The Menu item would need to be changed to "Templates..."
>
>
> Philippe has already do this for french translation ("Modèles..." not
> "Nouveau depuis modèles")
> I agree "Templates..." seems better.
>
>
>>
>>>>> After all, unless they change the template, they can just refetch it.
>>>>>
>>>>> Thoughts?
>>>>>
>

Re: New from Template silently overwrites files

Posted by Milamber <mi...@apache.org>.
Le 09/07/2013 13:20, sebb a ecrit :
> On 9 July 2013 13:01, sebb <se...@gmail.com> wrote:
>> On 9 July 2013 12:53, Milamber <mi...@apache.org> wrote:
>>> Le 09/07/2013 11:46, sebb a ecrit :
>>>
>>>> Just noticed that the "New From Template" feature creates a file in
>>>> the current working directory.
>>>>
>>>> It silently overwrites any file with the same name as the template.
>>>>
>>>> It would be easy to lose a valuable test plan.
>>>>
>>>> I'm not sure why the code does not just load the content from the
>>>> template, and leave to the user to save the test plan where they wish.
>>>
>>> +1, I would be better to make like "merge" (or use the merge functionalty)
>>> to open the template.
>>>
>> Yes - would need to clear any existing plan first though.
>>
> Just occurs to me that one might want to use templates for partial test plans?

Yes, I think it's natural to use the template as partial test plans 
(like "add my favorite listener")

>
> If so, then it would be useful not to clear the existing plan first.

Yes. Perhaps a checkbox "Replace (and remove) current test plan" or 
"Merge with current test plans".

>
> Maybe the templates.xml file could include a flag to say whether the
> template was a complete test plan or just a snippet?
> That would allow the dialog box to easily distinguish the two types.

+1

>
> The Menu item would need to be changed to "Templates..."

Philippe has already do this for french translation ("Modèles..." not 
"Nouveau depuis modèles")
I agree "Templates..." seems better.

>
>>>> After all, unless they change the template, they can just refetch it.
>>>>
>>>> Thoughts?
>>>>


Re: New from Template silently overwrites files

Posted by sebb <se...@gmail.com>.
On 9 July 2013 13:01, sebb <se...@gmail.com> wrote:
> On 9 July 2013 12:53, Milamber <mi...@apache.org> wrote:
>>
>> Le 09/07/2013 11:46, sebb a ecrit :
>>
>>> Just noticed that the "New From Template" feature creates a file in
>>> the current working directory.
>>>
>>> It silently overwrites any file with the same name as the template.
>>>
>>> It would be easy to lose a valuable test plan.
>>>
>>> I'm not sure why the code does not just load the content from the
>>> template, and leave to the user to save the test plan where they wish.
>>
>>
>> +1, I would be better to make like "merge" (or use the merge functionalty)
>> to open the template.
>>
>
> Yes - would need to clear any existing plan first though.
>

Just occurs to me that one might want to use templates for partial test plans?

If so, then it would be useful not to clear the existing plan first.

Maybe the templates.xml file could include a flag to say whether the
template was a complete test plan or just a snippet?
That would allow the dialog box to easily distinguish the two types.

The Menu item would need to be changed to "Templates..."

>>
>>> After all, unless they change the template, they can just refetch it.
>>>
>>> Thoughts?
>>>
>>

Re: New from Template silently overwrites files

Posted by sebb <se...@gmail.com>.
On 9 July 2013 12:53, Milamber <mi...@apache.org> wrote:
>
> Le 09/07/2013 11:46, sebb a ecrit :
>
>> Just noticed that the "New From Template" feature creates a file in
>> the current working directory.
>>
>> It silently overwrites any file with the same name as the template.
>>
>> It would be easy to lose a valuable test plan.
>>
>> I'm not sure why the code does not just load the content from the
>> template, and leave to the user to save the test plan where they wish.
>
>
> +1, I would be better to make like "merge" (or use the merge functionalty)
> to open the template.
>

Yes - would need to clear any existing plan first though.

>
>> After all, unless they change the template, they can just refetch it.
>>
>> Thoughts?
>>
>

Re: New from Template silently overwrites files

Posted by Milamber <mi...@apache.org>.
Le 09/07/2013 11:46, sebb a ecrit :
> Just noticed that the "New From Template" feature creates a file in
> the current working directory.
>
> It silently overwrites any file with the same name as the template.
>
> It would be easy to lose a valuable test plan.
>
> I'm not sure why the code does not just load the content from the
> template, and leave to the user to save the test plan where they wish.

+1, I would be better to make like "merge" (or use the merge 
functionalty) to open the template.

> After all, unless they change the template, they can just refetch it.
>
> Thoughts?
>