You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by Braden Shepherdson <br...@chromium.org> on 2013/10/17 18:28:09 UTC

CLI and Plugman test failures

We are adding CLI and Plugman master to our continuous builds. That means I
will start getting nag emails whenever they break, and I will be sending
frowny emails to the authors of those commits.

Run the tests! It's easy, just run npm test, in either repo. They only take
a couple of seconds.

Plugman is currently green.

CLI has several separate failures. I bisected some windows8 failures to one
patch[1] there are several other groups of failures. If you've worked on
CLI in the last couple of weeks, please run the tests or look at my log
below[2] and see what failures might be the result of your changes, or in a
platform you're responsible for.


Braden

[1]
https://git-wip-us.apache.org/repos/asf?p=cordova-cli.git;a=commit;h=fecd81afcd23b6395d1569638e387721fd734adc
[2] Log of running CLI tests (on Mac):


> cordova@3.1.0-0.2.0 test /Users/braden/cordova/cli/cordova-cli
> jasmine-node --color spec

................................F.........................................................................................................................F..........................FFF{
text: './/Application',
  attrib: { Id: 'testname', Version: 'one point oh' },
  VisualElements: { attrib: { DisplayName: 'old' } } }
.{ text: './/Application',
  attrib: { Id: 'testname', Version: 'one point oh' },
  VisualElements: { attrib: { DisplayName: 'old' } } }
.{ text: './/Application',
  attrib: { Id: 'testname', Version: 'one point oh' },
  VisualElements: { attrib: { DisplayName: 'old' } } }
.........F..................F.FFF.......................................................................cp:
no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

.cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

.cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

.cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

.cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

.cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

.cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

.cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

cp: no such file or directory: /some/path/www/config.xml

.cp: no such file or directory: /some/path/www/config.xml

........................................................

Failures:

  1) config.xml parser methods merge_with should handle namespaced elements
   Message:
     TypeError: Object #<Object> has no method ':'
   Stacktrace:
     TypeError: Object #<Object> has no method ':'
    at findall
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementpath.js:284:21)
    at Object.find
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementpath.js:321:23)
    at Element.find
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementtree.js:123:22)
    at mergeChild
(/Users/braden/cordova/cli/cordova-cli/src/config_parser.js:115:47)
    at Array.forEach (native)
    at mergeXml
(/Users/braden/cordova/cli/cordova-cli/src/config_parser.js:94:35)
    at Object.config_parser.merge_with
(/Users/braden/cordova/cli/cordova-cli/src/config_parser.js:71:9)
    at null.<anonymous>
(/Users/braden/cordova/cli/cordova-cli/spec/config_parser.spec.js:129:21)
    at jasmine.Block.execute
(/Users/braden/cordova/cli/cordova-cli/node_modules/jasmine-node/lib/jasmine-node/jasmine-1.3.1.js:1064:17)
    at jasmine.Queue.next_
(/Users/braden/cordova/cli/cordova-cli/node_modules/jasmine-node/lib/jasmine-node/jasmine-1.3.1.js:2096:31)

  2) firefoxos project parser instance update_from_config method should
write manifest.webapp
   Message:
     Error: Unexpected end
Line: 0
Column: 0
Char:
   Stacktrace:
     Error: Unexpected end
Line: 0
Column: 0
Char:
    at error
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:347:8)
    at end
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:354:32)
    at Object.write
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:588:30)
    at Object.SAXParser.close
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:136:38)
    at XMLParser.close
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/parsers/sax.js:52:15)
    at ElementTree.parse
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementtree.js:264:23)
    at Object.exports.XML
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementtree.js:593:13)
    at Object.module.exports.parseElementtreeSync
(/Users/braden/cordova/cli/cordova-cli/src/xml-helpers.js:115:38)
    at Object.config_parser
(/Users/braden/cordova/cli/cordova-cli/src/config_parser.js:25:20)
    at null.<anonymous>
(/Users/braden/cordova/cli/cordova-cli/spec/metadata/firefoxos_parser.spec.js:67:23)

  3) windows8 project parser check_requirements should fire a callback if
there is an error during shelling out
   Message:
     timeout: timed out after 10000 msec waiting for spec to complete
   Stacktrace:
     undefined

  4) windows8 project parser check_requirements should check by calling
check_reqs on the stock lib path if no custom path is defined
   Message:
     timeout: timed out after 10000 msec waiting for spec to complete
   Stacktrace:
     undefined

  5) windows8 project parser check_requirements should check by calling
check_reqs on a custom path if it is so defined
   Message:
     timeout: timed out after 10000 msec waiting for spec to complete
   Stacktrace:
     undefined

  6) windows8 project parser instance update_project method should throw if
update_from_config throws
   Message:
     timeout: timed out after 10000 msec waiting for spec to complete
   Stacktrace:
     undefined

  7) wp7 project parser instance update_project method should call
update_from_config
   Message:
     Error: Unexpected end
Line: 0
Column: 0
Char:
   Stacktrace:
     Error: Unexpected end
Line: 0
Column: 0
Char:
    at error
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:347:8)
    at end
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:354:32)
    at Object.write
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:588:30)
    at Object.SAXParser.close
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:136:38)
    at XMLParser.close
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/parsers/sax.js:52:15)
    at ElementTree.parse
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementtree.js:264:23)
    at Object.exports.XML
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementtree.js:593:13)
    at Object.module.exports.parseElementtreeSync
(/Users/braden/cordova/cli/cordova-cli/src/xml-helpers.js:115:38)
    at Object.module.exports.update_csproj
(/Users/braden/cordova/cli/cordova-cli/src/metadata/wp7_parser.js:177:30)
    at Object.module.exports.update_project
(/Users/braden/cordova/cli/cordova-cli/src/metadata/wp7_parser.js:256:14)

  8) wp7 project parser instance update_project method should call
update_www
   Message:
     Error: Unexpected end
Line: 0
Column: 0
Char:
   Stacktrace:
     Error: Unexpected end
Line: 0
Column: 0
Char:
    at error
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:347:8)
    at end
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:354:32)
    at Object.write
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:588:30)
    at Object.SAXParser.close
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:136:38)
    at XMLParser.close
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/parsers/sax.js:52:15)
    at ElementTree.parse
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementtree.js:264:23)
    at Object.exports.XML
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementtree.js:593:13)
    at Object.module.exports.parseElementtreeSync
(/Users/braden/cordova/cli/cordova-cli/src/xml-helpers.js:115:38)
    at Object.module.exports.update_csproj
(/Users/braden/cordova/cli/cordova-cli/src/metadata/wp7_parser.js:177:30)
    at Object.module.exports.update_project
(/Users/braden/cordova/cli/cordova-cli/src/metadata/wp7_parser.js:256:14)

  9) wp7 project parser instance update_project method should call
update_staging
   Message:
     Error: Unexpected end
Line: 0
Column: 0
Char:
   Stacktrace:
     Error: Unexpected end
Line: 0
Column: 0
Char:
    at error
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:347:8)
    at end
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:354:32)
    at Object.write
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:588:30)
    at Object.SAXParser.close
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:136:38)
    at XMLParser.close
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/parsers/sax.js:52:15)
    at ElementTree.parse
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementtree.js:264:23)
    at Object.exports.XML
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementtree.js:593:13)
    at Object.module.exports.parseElementtreeSync
(/Users/braden/cordova/cli/cordova-cli/src/xml-helpers.js:115:38)
    at Object.module.exports.update_csproj
(/Users/braden/cordova/cli/cordova-cli/src/metadata/wp7_parser.js:177:30)
    at Object.module.exports.update_project
(/Users/braden/cordova/cli/cordova-cli/src/metadata/wp7_parser.js:256:14)

  10) wp7 project parser instance update_project method should call
deleteSvnFolders
   Message:
     Error: Unexpected end
Line: 0
Column: 0
Char:
   Stacktrace:
     Error: Unexpected end
Line: 0
Column: 0
Char:
    at error
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:347:8)
    at end
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:354:32)
    at Object.write
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:588:30)
    at Object.SAXParser.close
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/node_modules/sax/lib/sax.js:136:38)
    at XMLParser.close
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/parsers/sax.js:52:15)
    at ElementTree.parse
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementtree.js:264:23)
    at Object.exports.XML
(/Users/braden/cordova/cli/cordova-cli/node_modules/elementtree/lib/elementtree.js:593:13)
    at Object.module.exports.parseElementtreeSync
(/Users/braden/cordova/cli/cordova-cli/src/xml-helpers.js:115:38)
    at Object.module.exports.update_csproj
(/Users/braden/cordova/cli/cordova-cli/src/metadata/wp7_parser.js:177:30)
    at Object.module.exports.update_project
(/Users/braden/cordova/cli/cordova-cli/src/metadata/wp7_parser.js:256:14)

Finished in 47.481 seconds
354 tests, 591 assertions, 10 failures


npm ERR! weird error 1
npm ERR! not ok code 0

Re: CLI and Plugman test failures

Posted by purplecabbage <pu...@gmail.com>.
Yeah the windows8 tests were in a branch without promises, and did not exist for you to vigorously patch. 

Sent from my iPhone

> On Oct 17, 2013, at 10:48 AM, Braden Shepherdson <br...@chromium.org> wrote:
> 
> I fixed all the tests vigorously when I was making that refactoring. If
> people have been adding lazy[1] tests similar to the ones I was fixing,
> then they're not going to work.
> 
> [1] By "lazy tests", I mean tests that are really testing async functions,
> but only mocking things that are called immediately, so they pretend the
> call is synchronous. Most of those were broken by the refactoring.
> 
> Since jasmine-node supports the 'done' argument, it's pretty easy to put
> your expectations into a .then() and then call done().
> 
> Braden
> 
> 
> On Thu, Oct 17, 2013 at 1:44 PM, purplecabbage <pu...@gmail.com>wrote:
> 
>> I believe the failures are the result of promise additions. Some 'expects'
>> will have to wait.
>> 
>> The error I kept seeing is an attempt to shell.rm
>> 
>> Sent from my iPhone
>> 
>>>> On Oct 17, 2013, at 10:21 AM, Steven Gill <st...@gmail.com>
>>> wrote:
>>> 
>>> I actually created an issue about cleaning up the tests yesterday
>> evening.
>>> https://issues.apache.org/jira/browse/CB-5106
>>> 
>>> I am planning on spending some time today and trying to get those
>> failures
>>> fixed. I also need to add some new tests.
>>> 
>>> 
>>> 
>>> 
>>> On Thu, Oct 17, 2013 at 10:17 AM, Braden Shepherdson <
>> braden@chromium.org>wrote:
>>> 
>>>> They might be related to an error, they might not. Either way, they're a
>>>> bug that needs fixing because they're not supposed to be in the output.
>>>> Similarly for the handful of JSON blurbs inside the dots at the top.
>>>> 
>>>> Braden
>>>> 
>>>> 
>>>> On Thu, Oct 17, 2013 at 12:44 PM, Ian Clelland <iclelland@chromium.org
>>>>> wrote:
>>>> 
>>>>> Are the repeated
>>>>> 
>>>>> cp: no such file or directory: /some/path/www/config.xml
>>>>> lines an expected part of the output? I saw them when I committed my
>> last
>>>>> changes, and so I checked out a couple of commits behind master and saw
>>>>> that they still appeared. I committed my changes, figuring that at
>> least
>>>> I
>>>>> hadn't *introduced* any new error output, but I'm still not certain
>>>> whether
>>>>> those lines represent an actual error, or if they're just a side-effect
>>>> of
>>>>> running the tests.
>>>>> 
>>>>> Ian
>> 

Re: CLI and Plugman test failures

Posted by Braden Shepherdson <br...@chromium.org>.
I fixed all the tests vigorously when I was making that refactoring. If
people have been adding lazy[1] tests similar to the ones I was fixing,
then they're not going to work.

[1] By "lazy tests", I mean tests that are really testing async functions,
but only mocking things that are called immediately, so they pretend the
call is synchronous. Most of those were broken by the refactoring.

Since jasmine-node supports the 'done' argument, it's pretty easy to put
your expectations into a .then() and then call done().

Braden


On Thu, Oct 17, 2013 at 1:44 PM, purplecabbage <pu...@gmail.com>wrote:

> I believe the failures are the result of promise additions. Some 'expects'
> will have to wait.
>
> The error I kept seeing is an attempt to shell.rm
>
> Sent from my iPhone
>
> > On Oct 17, 2013, at 10:21 AM, Steven Gill <st...@gmail.com>
> wrote:
> >
> > I actually created an issue about cleaning up the tests yesterday
> evening.
> > https://issues.apache.org/jira/browse/CB-5106
> >
> > I am planning on spending some time today and trying to get those
> failures
> > fixed. I also need to add some new tests.
> >
> >
> >
> >
> > On Thu, Oct 17, 2013 at 10:17 AM, Braden Shepherdson <
> braden@chromium.org>wrote:
> >
> >> They might be related to an error, they might not. Either way, they're a
> >> bug that needs fixing because they're not supposed to be in the output.
> >> Similarly for the handful of JSON blurbs inside the dots at the top.
> >>
> >> Braden
> >>
> >>
> >> On Thu, Oct 17, 2013 at 12:44 PM, Ian Clelland <iclelland@chromium.org
> >>> wrote:
> >>
> >>> Are the repeated
> >>>
> >>> cp: no such file or directory: /some/path/www/config.xml
> >>> lines an expected part of the output? I saw them when I committed my
> last
> >>> changes, and so I checked out a couple of commits behind master and saw
> >>> that they still appeared. I committed my changes, figuring that at
> least
> >> I
> >>> hadn't *introduced* any new error output, but I'm still not certain
> >> whether
> >>> those lines represent an actual error, or if they're just a side-effect
> >> of
> >>> running the tests.
> >>>
> >>> Ian
> >>
>

Re: CLI and Plugman test failures

Posted by purplecabbage <pu...@gmail.com>.
I believe the failures are the result of promise additions. Some 'expects' will have to wait. 

The error I kept seeing is an attempt to shell.rm

Sent from my iPhone

> On Oct 17, 2013, at 10:21 AM, Steven Gill <st...@gmail.com> wrote:
> 
> I actually created an issue about cleaning up the tests yesterday evening.
> https://issues.apache.org/jira/browse/CB-5106
> 
> I am planning on spending some time today and trying to get those failures
> fixed. I also need to add some new tests.
> 
> 
> 
> 
> On Thu, Oct 17, 2013 at 10:17 AM, Braden Shepherdson <br...@chromium.org>wrote:
> 
>> They might be related to an error, they might not. Either way, they're a
>> bug that needs fixing because they're not supposed to be in the output.
>> Similarly for the handful of JSON blurbs inside the dots at the top.
>> 
>> Braden
>> 
>> 
>> On Thu, Oct 17, 2013 at 12:44 PM, Ian Clelland <iclelland@chromium.org
>>> wrote:
>> 
>>> Are the repeated
>>> 
>>> cp: no such file or directory: /some/path/www/config.xml
>>> lines an expected part of the output? I saw them when I committed my last
>>> changes, and so I checked out a couple of commits behind master and saw
>>> that they still appeared. I committed my changes, figuring that at least
>> I
>>> hadn't *introduced* any new error output, but I'm still not certain
>> whether
>>> those lines represent an actual error, or if they're just a side-effect
>> of
>>> running the tests.
>>> 
>>> Ian
>> 

Re: CLI and Plugman test failures

Posted by Steven Gill <st...@gmail.com>.
I actually created an issue about cleaning up the tests yesterday evening.
https://issues.apache.org/jira/browse/CB-5106

I am planning on spending some time today and trying to get those failures
fixed. I also need to add some new tests.




On Thu, Oct 17, 2013 at 10:17 AM, Braden Shepherdson <br...@chromium.org>wrote:

> They might be related to an error, they might not. Either way, they're a
> bug that needs fixing because they're not supposed to be in the output.
> Similarly for the handful of JSON blurbs inside the dots at the top.
>
> Braden
>
>
> On Thu, Oct 17, 2013 at 12:44 PM, Ian Clelland <iclelland@chromium.org
> >wrote:
>
> > Are the repeated
> >
> > cp: no such file or directory: /some/path/www/config.xml
> > >
> > >
> > lines an expected part of the output? I saw them when I committed my last
> > changes, and so I checked out a couple of commits behind master and saw
> > that they still appeared. I committed my changes, figuring that at least
> I
> > hadn't *introduced* any new error output, but I'm still not certain
> whether
> > those lines represent an actual error, or if they're just a side-effect
> of
> > running the tests.
> >
> > Ian
> >
>

Re: CLI and Plugman test failures

Posted by Braden Shepherdson <br...@chromium.org>.
They might be related to an error, they might not. Either way, they're a
bug that needs fixing because they're not supposed to be in the output.
Similarly for the handful of JSON blurbs inside the dots at the top.

Braden


On Thu, Oct 17, 2013 at 12:44 PM, Ian Clelland <ic...@chromium.org>wrote:

> Are the repeated
>
> cp: no such file or directory: /some/path/www/config.xml
> >
> >
> lines an expected part of the output? I saw them when I committed my last
> changes, and so I checked out a couple of commits behind master and saw
> that they still appeared. I committed my changes, figuring that at least I
> hadn't *introduced* any new error output, but I'm still not certain whether
> those lines represent an actual error, or if they're just a side-effect of
> running the tests.
>
> Ian
>

Re: CLI and Plugman test failures

Posted by Ian Clelland <ic...@chromium.org>.
Are the repeated

cp: no such file or directory: /some/path/www/config.xml
>
>
lines an expected part of the output? I saw them when I committed my last
changes, and so I checked out a couple of commits behind master and saw
that they still appeared. I committed my changes, figuring that at least I
hadn't *introduced* any new error output, but I'm still not certain whether
those lines represent an actual error, or if they're just a side-effect of
running the tests.

Ian