You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@wicket.apache.org by Martin Grigorov <mg...@apache.org> on 2013/06/17 15:05:40 UTC

JavaScript functional tests

Hi,

I just pushed branch "wicket-examples-gym-tests".
It contains some tests based on the idea described at
http://wicketinaction.com/2012/11/javascript-based-functional-testing/

To run the tests one has to start the examples and load
http://localhost:8080/js-test/all.html

Is there anyone against these tests ?
I'd like to add some coverage to Wicket Examples and to practice my JS
coding skills.

At the moment both the old JS tests (wicket-core/src/test/js) and these
ones should be executed manually. I can integrate them in Maven but them
all developers and CI machines should have Node.js
Do we want the tests in the build or should I leave them as now ?

Re: JavaScript functional tests

Posted by Cedric Gatay <ga...@gmail.com>.
I'll have a look at this, Jasmine can be cumbersome when it comes to IDE
support.

__
Cedric Gatay (@Cedric_Gatay <http://twitter.com/Cedric_Gatay>)
http://code-troopers.com | http://www.bloggure.info | http://cedric.gatay.fr


On Mon, Jun 17, 2013 at 7:19 PM, Martin Grigorov <mg...@apache.org>wrote:

> I use QUnit as testing library.
> Node.js is required only to automate the run of the tests (in headless
> mode) in PhantomJS (WebKit).
>
> At the moment I run the tests by just loading
> http://localhost:8080/js-test/all.html in any browser.
> Try it! You will like it!
>
> I'll merge the branch soon.
>
>
> On Mon, Jun 17, 2013 at 8:13 PM, Cedric Gatay <ga...@gmail.com> wrote:
>
> > Testing JS is a good thing to me, is there any other javascript testing
> > framework without such prerequisite (Node.js) ? At SRMvision, we use
> > Jasmine which does not require any other setup.
> >
> > Anyway, I think it should be part of the Maven build process if we want
> > them to be useful.
> >
> > Regards,
> >
> > __
> > Cedric Gatay (@Cedric_Gatay <http://twitter.com/Cedric_Gatay>)
> > http://code-troopers.com | http://www.bloggure.info |
> > http://cedric.gatay.fr
> >
> >
> > On Mon, Jun 17, 2013 at 4:20 PM, Martijn Dashorst <
> > martijn.dashorst@gmail.com> wrote:
> >
> > > No problem... the more tests the merrier
> > >
> > > Martijn
> > >
> > > On Mon, Jun 17, 2013 at 3:05 PM, Martin Grigorov <mgrigorov@apache.org
> >
> > > wrote:
> > > > Hi,
> > > >
> > > > I just pushed branch "wicket-examples-gym-tests".
> > > > It contains some tests based on the idea described at
> > > >
> http://wicketinaction.com/2012/11/javascript-based-functional-testing/
> > > >
> > > > To run the tests one has to start the examples and load
> > > > http://localhost:8080/js-test/all.html
> > > >
> > > > Is there anyone against these tests ?
> > > > I'd like to add some coverage to Wicket Examples and to practice my
> JS
> > > > coding skills.
> > > >
> > > > At the moment both the old JS tests (wicket-core/src/test/js) and
> these
> > > > ones should be executed manually. I can integrate them in Maven but
> > them
> > > > all developers and CI machines should have Node.js
> > > > Do we want the tests in the build or should I leave them as now ?
> > >
> > >
> > >
> > > --
> > > Become a Wicket expert, learn from the best: http://wicketinaction.com
> > >
> >
>

Re: JavaScript functional tests

Posted by Michael Mosmann <mi...@mosmann.de>.
Am 18.06.2013 15:20, schrieb Martin Grigorov:
> At the moment I run the tests from time to time manually by loading the
> respective url in the browsers.
>
> I can add Maven integration that will run the tests in PhantomJS during
> each 'mvn test' execution. The requirement here is that there is installed
> Node.js on the machine.
I have a project to download and start node.js automagical.. 
https://github.com/flapdoodle-oss/de.flapdoodle.embed.nodejs .. maybe we 
can put both things together..

>   It is needed to run PhantomJS.
> The related Maven config can be seen at
> https://github.com/martin-g/blogs/blob/master/functional-qunit/pom.xml#L65-L103
>
> Having it automated means that we will need this setup on the CI servers
> too.
>
>
> On Tue, Jun 18, 2013 at 4:06 PM, Jeremy Thomerson <jeremy@wickettraining.com
>> wrote:
>> Will we need to add this as a manual test step in our build / release
>> cycle?  Or will there be some way of automating it built into our release
>> script(s)?
>>
>>
>> On Mon, Jun 17, 2013 at 1:19 PM, Martin Grigorov <mgrigorov@apache.org
>>> wrote:
>>> I use QUnit as testing library.
>>> Node.js is required only to automate the run of the tests (in headless
>>> mode) in PhantomJS (WebKit).
>>>
>>> At the moment I run the tests by just loading
>>> http://localhost:8080/js-test/all.html in any browser.
>>> Try it! You will like it!
>>>
>>> I'll merge the branch soon.
>>>
>>>
>>> On Mon, Jun 17, 2013 at 8:13 PM, Cedric Gatay <ga...@gmail.com> wrote:
>>>
>>>> Testing JS is a good thing to me, is there any other javascript testing
>>>> framework without such prerequisite (Node.js) ? At SRMvision, we use
>>>> Jasmine which does not require any other setup.
>>>>
>>>> Anyway, I think it should be part of the Maven build process if we want
>>>> them to be useful.
>>>>
>>>> Regards,
>>>>
>>>> __
>>>> Cedric Gatay (@Cedric_Gatay <http://twitter.com/Cedric_Gatay>)
>>>> http://code-troopers.com | http://www.bloggure.info |
>>>> http://cedric.gatay.fr
>>>>
>>>>
>>>> On Mon, Jun 17, 2013 at 4:20 PM, Martijn Dashorst <
>>>> martijn.dashorst@gmail.com> wrote:
>>>>
>>>>> No problem... the more tests the merrier
>>>>>
>>>>> Martijn
>>>>>
>>>>> On Mon, Jun 17, 2013 at 3:05 PM, Martin Grigorov <
>> mgrigorov@apache.org
>>>>> wrote:
>>>>>> Hi,
>>>>>>
>>>>>> I just pushed branch "wicket-examples-gym-tests".
>>>>>> It contains some tests based on the idea described at
>>>>>>
>>> http://wicketinaction.com/2012/11/javascript-based-functional-testing/
>>>>>> To run the tests one has to start the examples and load
>>>>>> http://localhost:8080/js-test/all.html
>>>>>>
>>>>>> Is there anyone against these tests ?
>>>>>> I'd like to add some coverage to Wicket Examples and to practice my
>>> JS
>>>>>> coding skills.
>>>>>>
>>>>>> At the moment both the old JS tests (wicket-core/src/test/js) and
>>> these
>>>>>> ones should be executed manually. I can integrate them in Maven but
>>>> them
>>>>>> all developers and CI machines should have Node.js
>>>>>> Do we want the tests in the build or should I leave them as now ?
>>>>>
>>>>>
>>>>> --
>>>>> Become a Wicket expert, learn from the best:
>> http://wicketinaction.com
>>
>>
>> --
>> Jeremy Thomerson
>> http://wickettraining.com
>> *Ask me about our plans for on-line training lessons.*
>>


Re: JavaScript functional tests

Posted by Martin Grigorov <mg...@apache.org>.
At the moment I run the tests from time to time manually by loading the
respective url in the browsers.

I can add Maven integration that will run the tests in PhantomJS during
each 'mvn test' execution. The requirement here is that there is installed
Node.js on the machine. It is needed to run PhantomJS.
The related Maven config can be seen at
https://github.com/martin-g/blogs/blob/master/functional-qunit/pom.xml#L65-L103

Having it automated means that we will need this setup on the CI servers
too.


On Tue, Jun 18, 2013 at 4:06 PM, Jeremy Thomerson <jeremy@wickettraining.com
> wrote:

> Will we need to add this as a manual test step in our build / release
> cycle?  Or will there be some way of automating it built into our release
> script(s)?
>
>
> On Mon, Jun 17, 2013 at 1:19 PM, Martin Grigorov <mgrigorov@apache.org
> >wrote:
>
> > I use QUnit as testing library.
> > Node.js is required only to automate the run of the tests (in headless
> > mode) in PhantomJS (WebKit).
> >
> > At the moment I run the tests by just loading
> > http://localhost:8080/js-test/all.html in any browser.
> > Try it! You will like it!
> >
> > I'll merge the branch soon.
> >
> >
> > On Mon, Jun 17, 2013 at 8:13 PM, Cedric Gatay <ga...@gmail.com> wrote:
> >
> > > Testing JS is a good thing to me, is there any other javascript testing
> > > framework without such prerequisite (Node.js) ? At SRMvision, we use
> > > Jasmine which does not require any other setup.
> > >
> > > Anyway, I think it should be part of the Maven build process if we want
> > > them to be useful.
> > >
> > > Regards,
> > >
> > > __
> > > Cedric Gatay (@Cedric_Gatay <http://twitter.com/Cedric_Gatay>)
> > > http://code-troopers.com | http://www.bloggure.info |
> > > http://cedric.gatay.fr
> > >
> > >
> > > On Mon, Jun 17, 2013 at 4:20 PM, Martijn Dashorst <
> > > martijn.dashorst@gmail.com> wrote:
> > >
> > > > No problem... the more tests the merrier
> > > >
> > > > Martijn
> > > >
> > > > On Mon, Jun 17, 2013 at 3:05 PM, Martin Grigorov <
> mgrigorov@apache.org
> > >
> > > > wrote:
> > > > > Hi,
> > > > >
> > > > > I just pushed branch "wicket-examples-gym-tests".
> > > > > It contains some tests based on the idea described at
> > > > >
> > http://wicketinaction.com/2012/11/javascript-based-functional-testing/
> > > > >
> > > > > To run the tests one has to start the examples and load
> > > > > http://localhost:8080/js-test/all.html
> > > > >
> > > > > Is there anyone against these tests ?
> > > > > I'd like to add some coverage to Wicket Examples and to practice my
> > JS
> > > > > coding skills.
> > > > >
> > > > > At the moment both the old JS tests (wicket-core/src/test/js) and
> > these
> > > > > ones should be executed manually. I can integrate them in Maven but
> > > them
> > > > > all developers and CI machines should have Node.js
> > > > > Do we want the tests in the build or should I leave them as now ?
> > > >
> > > >
> > > >
> > > > --
> > > > Become a Wicket expert, learn from the best:
> http://wicketinaction.com
> > > >
> > >
> >
>
>
>
> --
> Jeremy Thomerson
> http://wickettraining.com
> *Ask me about our plans for on-line training lessons.*
>

Re: JavaScript functional tests

Posted by Jeremy Thomerson <je...@wickettraining.com>.
Will we need to add this as a manual test step in our build / release
cycle?  Or will there be some way of automating it built into our release
script(s)?


On Mon, Jun 17, 2013 at 1:19 PM, Martin Grigorov <mg...@apache.org>wrote:

> I use QUnit as testing library.
> Node.js is required only to automate the run of the tests (in headless
> mode) in PhantomJS (WebKit).
>
> At the moment I run the tests by just loading
> http://localhost:8080/js-test/all.html in any browser.
> Try it! You will like it!
>
> I'll merge the branch soon.
>
>
> On Mon, Jun 17, 2013 at 8:13 PM, Cedric Gatay <ga...@gmail.com> wrote:
>
> > Testing JS is a good thing to me, is there any other javascript testing
> > framework without such prerequisite (Node.js) ? At SRMvision, we use
> > Jasmine which does not require any other setup.
> >
> > Anyway, I think it should be part of the Maven build process if we want
> > them to be useful.
> >
> > Regards,
> >
> > __
> > Cedric Gatay (@Cedric_Gatay <http://twitter.com/Cedric_Gatay>)
> > http://code-troopers.com | http://www.bloggure.info |
> > http://cedric.gatay.fr
> >
> >
> > On Mon, Jun 17, 2013 at 4:20 PM, Martijn Dashorst <
> > martijn.dashorst@gmail.com> wrote:
> >
> > > No problem... the more tests the merrier
> > >
> > > Martijn
> > >
> > > On Mon, Jun 17, 2013 at 3:05 PM, Martin Grigorov <mgrigorov@apache.org
> >
> > > wrote:
> > > > Hi,
> > > >
> > > > I just pushed branch "wicket-examples-gym-tests".
> > > > It contains some tests based on the idea described at
> > > >
> http://wicketinaction.com/2012/11/javascript-based-functional-testing/
> > > >
> > > > To run the tests one has to start the examples and load
> > > > http://localhost:8080/js-test/all.html
> > > >
> > > > Is there anyone against these tests ?
> > > > I'd like to add some coverage to Wicket Examples and to practice my
> JS
> > > > coding skills.
> > > >
> > > > At the moment both the old JS tests (wicket-core/src/test/js) and
> these
> > > > ones should be executed manually. I can integrate them in Maven but
> > them
> > > > all developers and CI machines should have Node.js
> > > > Do we want the tests in the build or should I leave them as now ?
> > >
> > >
> > >
> > > --
> > > Become a Wicket expert, learn from the best: http://wicketinaction.com
> > >
> >
>



-- 
Jeremy Thomerson
http://wickettraining.com
*Ask me about our plans for on-line training lessons.*

Re: JavaScript functional tests

Posted by Martin Grigorov <mg...@apache.org>.
I use QUnit as testing library.
Node.js is required only to automate the run of the tests (in headless
mode) in PhantomJS (WebKit).

At the moment I run the tests by just loading
http://localhost:8080/js-test/all.html in any browser.
Try it! You will like it!

I'll merge the branch soon.


On Mon, Jun 17, 2013 at 8:13 PM, Cedric Gatay <ga...@gmail.com> wrote:

> Testing JS is a good thing to me, is there any other javascript testing
> framework without such prerequisite (Node.js) ? At SRMvision, we use
> Jasmine which does not require any other setup.
>
> Anyway, I think it should be part of the Maven build process if we want
> them to be useful.
>
> Regards,
>
> __
> Cedric Gatay (@Cedric_Gatay <http://twitter.com/Cedric_Gatay>)
> http://code-troopers.com | http://www.bloggure.info |
> http://cedric.gatay.fr
>
>
> On Mon, Jun 17, 2013 at 4:20 PM, Martijn Dashorst <
> martijn.dashorst@gmail.com> wrote:
>
> > No problem... the more tests the merrier
> >
> > Martijn
> >
> > On Mon, Jun 17, 2013 at 3:05 PM, Martin Grigorov <mg...@apache.org>
> > wrote:
> > > Hi,
> > >
> > > I just pushed branch "wicket-examples-gym-tests".
> > > It contains some tests based on the idea described at
> > > http://wicketinaction.com/2012/11/javascript-based-functional-testing/
> > >
> > > To run the tests one has to start the examples and load
> > > http://localhost:8080/js-test/all.html
> > >
> > > Is there anyone against these tests ?
> > > I'd like to add some coverage to Wicket Examples and to practice my JS
> > > coding skills.
> > >
> > > At the moment both the old JS tests (wicket-core/src/test/js) and these
> > > ones should be executed manually. I can integrate them in Maven but
> them
> > > all developers and CI machines should have Node.js
> > > Do we want the tests in the build or should I leave them as now ?
> >
> >
> >
> > --
> > Become a Wicket expert, learn from the best: http://wicketinaction.com
> >
>

Re: JavaScript functional tests

Posted by Cedric Gatay <ga...@gmail.com>.
Testing JS is a good thing to me, is there any other javascript testing
framework without such prerequisite (Node.js) ? At SRMvision, we use
Jasmine which does not require any other setup.

Anyway, I think it should be part of the Maven build process if we want
them to be useful.

Regards,

__
Cedric Gatay (@Cedric_Gatay <http://twitter.com/Cedric_Gatay>)
http://code-troopers.com | http://www.bloggure.info | http://cedric.gatay.fr


On Mon, Jun 17, 2013 at 4:20 PM, Martijn Dashorst <
martijn.dashorst@gmail.com> wrote:

> No problem... the more tests the merrier
>
> Martijn
>
> On Mon, Jun 17, 2013 at 3:05 PM, Martin Grigorov <mg...@apache.org>
> wrote:
> > Hi,
> >
> > I just pushed branch "wicket-examples-gym-tests".
> > It contains some tests based on the idea described at
> > http://wicketinaction.com/2012/11/javascript-based-functional-testing/
> >
> > To run the tests one has to start the examples and load
> > http://localhost:8080/js-test/all.html
> >
> > Is there anyone against these tests ?
> > I'd like to add some coverage to Wicket Examples and to practice my JS
> > coding skills.
> >
> > At the moment both the old JS tests (wicket-core/src/test/js) and these
> > ones should be executed manually. I can integrate them in Maven but them
> > all developers and CI machines should have Node.js
> > Do we want the tests in the build or should I leave them as now ?
>
>
>
> --
> Become a Wicket expert, learn from the best: http://wicketinaction.com
>

Re: JavaScript functional tests

Posted by Martijn Dashorst <ma...@gmail.com>.
No problem... the more tests the merrier

Martijn

On Mon, Jun 17, 2013 at 3:05 PM, Martin Grigorov <mg...@apache.org> wrote:
> Hi,
>
> I just pushed branch "wicket-examples-gym-tests".
> It contains some tests based on the idea described at
> http://wicketinaction.com/2012/11/javascript-based-functional-testing/
>
> To run the tests one has to start the examples and load
> http://localhost:8080/js-test/all.html
>
> Is there anyone against these tests ?
> I'd like to add some coverage to Wicket Examples and to practice my JS
> coding skills.
>
> At the moment both the old JS tests (wicket-core/src/test/js) and these
> ones should be executed manually. I can integrate them in Maven but them
> all developers and CI machines should have Node.js
> Do we want the tests in the build or should I leave them as now ?



-- 
Become a Wicket expert, learn from the best: http://wicketinaction.com