You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@shindig.apache.org by Mike Samuel <mi...@gmail.com> on 2008/03/05 02:22:20 UTC

testing html-sanitizer.js

I'm a dev on Caja ( http://code.google.com/p/google-caja/ ).  I'd like to
update the javascript html sanitizer and container under
shindig/features/caja to Caja's latest and greatest.

I found that under shindig/features/caja but I can't find any of the
corresponding testcases:
http://cajadores.com/snapshot/com/google/caja/plugin/test-sanitize.html

Should those be in Shindig?  If so, where should they go?  And does Shindig
have any infrastructure for running javascript tests in java, like
http://code.google.com/p/google-caja/source/browse/trunk/src/javatests/com/google/caja/util/RhinoTestBed.java

cheers,
mike

Re: testing html-sanitizer.js

Posted by Kevin Brown <et...@google.com>.
On Tue, Mar 4, 2008 at 6:44 PM, Mike Samuel <mi...@gmail.com> wrote:

>
>
> On 04/03/2008, Kevin Brown <et...@google.com> wrote:
> >
> > On Tue, Mar 4, 2008 at 5:22 PM, Mike Samuel <mi...@gmail.com>
> > wrote:
> >
> > > I'm a dev on Caja ( http://code.google.com/p/google-caja/ ).  I'd like
> > > to
> > > update the javascript html sanitizer and container under
> > > shindig/features/caja to Caja's latest and greatest.
> > >
> > > I found that under shindig/features/caja but I can't find any of the
> > > corresponding testcases:
> > >
> > > http://cajadores.com/snapshot/com/google/caja/plugin/test-sanitize.html
> > >
> > > Should those be in Shindig?
> >
> >
> > Ideally not -- I'd rather not have the js in there either though, and
> > would instead pull it from your maven repo. Is this possible? If it's inside
> > of the caja jar, I can make it work as well (i just need to know the full
> > resource path)
> >
>
> I'll check with Mike Stay and see if they are.
> The resource path will be
>   com/google/caja/plugin/html-sanitizer.js
>   com/google/caja/plugin/html4-defs.js
>   com/google/caja/plugin/unicode.js
>   com/google/caja/plugin/domita.js
>
> I'll post a patch that modifies features/opensocial-reference/container.js
> and removes features/caja/html-sanitizer.js then.
>
> I see build instructions at
> http://incubator.apache.org/shindig/#getTheCode, but how do I run tests,
> and which tests should I run?
>

All tests are run by every time you build. I'm actually not even sure how to
*not* run the tests, which has become a bit of a problem now that there are
over 100.


>
> If so, where should they go?  And does Shindig
> > > have any infrastructure for running javascript tests in java, like
> > >
> > > http://code.google.com/p/google-caja/source/browse/trunk/src/javatests/com/google/caja/util/RhinoTestBed.java
> >
> >
> > We don't, but we want to have something like this. Can we steal it? :)
> >
>
> It's under the Apache License.  Steal away.
>

Awesome.
-- 
~Kevin

Re: testing html-sanitizer.js

Posted by Mike Samuel <mi...@gmail.com>.
On 04/03/2008, Kevin Brown <et...@google.com> wrote:
>
> On Tue, Mar 4, 2008 at 5:22 PM, Mike Samuel <mi...@gmail.com> wrote:
>
> > I'm a dev on Caja ( http://code.google.com/p/google-caja/ ).  I'd like
> > to
> > update the javascript html sanitizer and container under
> > shindig/features/caja to Caja's latest and greatest.
> >
> > I found that under shindig/features/caja but I can't find any of the
> > corresponding testcases:
> > http://cajadores.com/snapshot/com/google/caja/plugin/test-sanitize.html
> >
> > Should those be in Shindig?
>
>
> Ideally not -- I'd rather not have the js in there either though, and
> would instead pull it from your maven repo. Is this possible? If it's inside
> of the caja jar, I can make it work as well (i just need to know the full
> resource path)
>

I'll check with Mike Stay and see if they are.
The resource path will be
  com/google/caja/plugin/html-sanitizer.js
  com/google/caja/plugin/html4-defs.js
  com/google/caja/plugin/unicode.js
  com/google/caja/plugin/domita.js

I'll post a patch that modifies features/opensocial-reference/container.js
and removes features/caja/html-sanitizer.js then.

I see build instructions at http://incubator.apache.org/shindig/#getTheCode,
but how do I run tests, and which tests should I run?




If so, where should they go?  And does Shindig
> > have any infrastructure for running javascript tests in java, like
> >
> > http://code.google.com/p/google-caja/source/browse/trunk/src/javatests/com/google/caja/util/RhinoTestBed.java
>
>
> We don't, but we want to have something like this. Can we steal it? :)
>

It's under the Apache License.  Steal away.



cheers,
> > mike
> >
>
>
>
> --
> ~Kevin

Re: testing html-sanitizer.js

Posted by Kevin Brown <et...@google.com>.
On Tue, Mar 4, 2008 at 5:22 PM, Mike Samuel <mi...@gmail.com> wrote:

> I'm a dev on Caja ( http://code.google.com/p/google-caja/ ).  I'd like to
> update the javascript html sanitizer and container under
> shindig/features/caja to Caja's latest and greatest.
>
> I found that under shindig/features/caja but I can't find any of the
> corresponding testcases:
> http://cajadores.com/snapshot/com/google/caja/plugin/test-sanitize.html
>
> Should those be in Shindig?


Ideally not -- I'd rather not have the js in there either though, and would
instead pull it from your maven repo. Is this possible? If it's inside of
the caja jar, I can make it work as well (i just need to know the full
resource path)

If so, where should they go?  And does Shindig
> have any infrastructure for running javascript tests in java, like
>
> http://code.google.com/p/google-caja/source/browse/trunk/src/javatests/com/google/caja/util/RhinoTestBed.java


We don't, but we want to have something like this. Can we steal it? :)

>
> <http://code.google.com/p/google-caja/source/browse/trunk/src/javatests/com/google/caja/util/RhinoTestBed.java>
>
> cheers,
> mike
>



-- 
~Kevin