Skip to content

power-assert graph missing from TAP output #399

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
alubbe opened this issue Jan 1, 2016 · 7 comments
Closed

power-assert graph missing from TAP output #399

alubbe opened this issue Jan 1, 2016 · 7 comments
Assignees
Labels
bug current functionality does not work as desired help wanted

Comments

@alubbe
Copy link

alubbe commented Jan 1, 2016

Thanks for the awesome TAP support, although I suspect it is really all about nyan-cat.
I noticed that piping the output meant losing the awesomeness of power-assert - is that inherent to supporting TAP at all or is there someway we can have flying rainbow cats and nice asserts?

@jamestalmage
Copy link
Contributor

Hmm. That should not be true. It's probably a bug from when we moved power-assert rendering to the main thread. I will look into it.

@jamestalmage jamestalmage added the bug current functionality does not work as desired label Jan 1, 2016
@jamestalmage jamestalmage self-assigned this Jan 1, 2016
@alubbe
Copy link
Author

alubbe commented Jan 1, 2016

To reproduce, I ran ava --tap test/*.js | tnyan on 0.9.1

@jamestalmage
Copy link
Contributor

Seems specific to the tap-nyan reporter

I had better success with:

./cli.js --tap test/fixture/power-assert.js | tap-spec
./cli.js --tap test/fixture/power-assert.js | tap-mocha-reporter nyan

@alubbe
Copy link
Author

alubbe commented Jan 2, 2016

Somewhat better, using tap-mocha-reporter I get

  t.ok(res.statusCode === 202)-----,
           |                   /\_/\ 
           200                ( ^ .^) 
 228 _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-__,------,
 1   _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-__|  /\_/\  
 0   _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_~|_( x .x)  
     _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ ""  ""  

  1 passing (4s)
  1 failing

  1) :
     (unnamed error)

Now the cat output is part of the assert (not a biggie), but something ate the stack trace. Here is what it looks like with the default reporter:

  1 passed  1 failed

  1. foo › bar

  t.ok(res.statusCode === 202)
           |                  
           200                

  AssertionError: false == true
    at Decorator.concreteAssert (node_modules/empower-core/lib/decorator.js:95:20)
    at Object.decoratedAssert [as ok] (node_modules/empower-core/lib/decorate.js:48:30)
    at Test._callee$ (test/test.coffee:28:5)
    at tryCatch (node_modules/babel-runtime/regenerator/runtime.js:88:40)
    at GeneratorFunctionPrototype.invoke [as _invoke] (node_modules/babel-runtime/regenerator/runtime.js:341:22)
    at GeneratorFunctionPrototype.prototype.(anonymous function) [as next] (node_modules/babel-runtime/regenerator/runtime.js:121:21)
    at onFulfilled (node_modules/co-with-promise/index.js:66:19)

@novemberborn
Copy link
Member

@jamestalmage what are our next steps on this?

@jamestalmage jamestalmage mentioned this issue Apr 5, 2016
7 tasks
@novemberborn
Copy link
Member

The issue here is that our TAP output does not include the power-assert graph. I'm not sure if that's even possible within the TAP specification, and how that would interact with say tap-nyan. #723 suggests using the TAP v14 specification which may or may not be a prerequisite for resolving this.

See also #324.

@novemberborn novemberborn changed the title TAP and power-assert power-assert graph missing from TAP output Sep 21, 2016
@novemberborn
Copy link
Member

We now do include the formatted values (based on power-assert) to the TAP output. It's a proprietary format and thus not very useful, but that's a separate concern.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug current functionality does not work as desired help wanted
Projects
None yet
Development

No branches or pull requests

3 participants