Skip to content

Is it possible to connect pytest assert failures to problems and code views? #120

Closed

Description

From hendrics on May 21, 2017 20:15

Hi. I was wondering if there's an option to integrate assert failures and problem/code view.

I managed to hack it together using problemMatchers for tasks.
See the details example here
https://github.com/hendrics/python-vscode-pytest-example

Also i am looking for an ability to add links to the Output view to jump to the code.
There are open issues on the vscode to address it via matchers.

So overall copy pasting the tasks.json around is not scalable and i am wondering
if there's scope to add it to this extension unless it is already implemented.

Environment data

VS Code version: Version 1.12.2 (1.12.2)
Python Extension version: Version 0.6.4 (4 May 2017)
Python Version: 2.7.11
OS and version: macOS El Capitan

Copied from original issue: DonJayamanne/pythonVSCode#973

Activity

  1. DonJayamanne commented on Nov 13, 2017

    @DonJayamanne
    Author

    Does sound like a good suggestion, however what's interesting is that this hasn't been up voted by anyone. I'll check this feature with my colleagues and get back to you. There could be other edge cases that need to be considered, e.g. what if the unit tests pass, we'll then need to ensure the problems disappear.

  2. changed the title [-]Is it possible connect pytest assert failures to problems and code views?[/-] [+]Is it possible to connect pytest assert failures to problems and code views?[/+] on Nov 14, 2017
  3. 1 remaining item

  4. DonJayamanne commented on Dec 20, 2018

    @DonJayamanne
    Author

    screen shot 2018-12-20 at 3 34 14 pm

    screen shot 2018-12-20 at 3 34 24 pm

  5. DonJayamanne commented on Dec 20, 2018

    @DonJayamanne
    Author

    screen shot 2018-12-20 at 3 39 36 pm

  6. ghost removed on Jan 7, 2019
  7. orn688 commented on Jan 29, 2019

    @orn688

    This is a great feature, but is there a way to disable the red underlines for failing tests? I think of the red underlines as indicating linting/syntax errors, so I find it a bit confusing that they're overloaded to indicate test failures. Thanks for working on this though!

  8. DonJayamanne commented on Jan 29, 2019

    @DonJayamanne
    Author

    Please create a separate issue and we can go from there.

  9. locked as resolved and limited conversation to collaborators on Feb 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

area-testingfeature-requestRequest for new features or functionalityimportantIssue identified as high-priority

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions