forked from DonJayamanne/pythonVSCode
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Closed
Labels
bugIssue identified by VS Code Team member as probable bugIssue identified by VS Code Team member as probable bug
Description
Environment data
- VS Code version: 1.42.0-insider
- Extension version: 2020.1.56281-dev
Steps to reproduce:
- Launch VSC and create python file named unit_test.py in folder1
a. Clear the part of workspace configuration in setting.json - Enter below code:
import unittest
class PassingTests(unittest.TestCase):
def test_passing(self):
self.assertEqual(42, 42)
def test_passing_still(self):
self.assertEqual("silly walk", "silly walk")
class FailingTests(unittest.TestCase):
def test_failure(self):
self.assertEqual(42, -13)
def test_failure_still(self):
self.assertEqual("I'm right!", "no, I am!") - Repeat step1,2 but in folder2
- Run "Run All Unit Tests", ensure:
a. triggers the prompt to configure the test runner
a). Click "Enable and configure a test framework"
b). Select "Unittest" and next ". Root directory"
c). Select first test file name format
Expected behavior
Tests are discovered (as shown by code lenses on each test)

Actual behavior
This issue reproduced on Python2.7, Python3.7 and Anaconda environments.
Metadata
Metadata
Assignees
Labels
bugIssue identified by VS Code Team member as probable bugIssue identified by VS Code Team member as probable bug
