Python Forum
Search Results
Post Author Forum Replies Views Posted [asc]
    Thread: VSCode not able to discover tests
Post: RE: VSCode not able to discover tests

I found the mistake based on your previous post. Thanks. The function names started with 'Test' when these should start with 'test'. It seems it is case-sensitive. After changing function name to 't...
rpk2006 General Coding Help 5 10,968 Jul-15-2020, 05:49 AM
    Thread: VSCode not able to discover tests
Post: RE: VSCode not able to discover tests

Sorry, I edited the original post but that code is not appearing. I tried both. pyTest code is as below: import pytest def TestSum(): assert AddNum(5,6) == 11 def TestDiff(): assert Su...
rpk2006 General Coding Help 5 10,968 Jul-15-2020, 05:01 AM
    Thread: VSCode not able to discover tests
Post: VSCode not able to discover tests

My test file is as below: from unittest import TestCase import pytest class TestNumbers(TestCase): def TestSum(self): self.assertEqual(AddNum(5,6), 11) def TestDiff(self): ...
rpk2006 General Coding Help 5 10,968 Jul-15-2020, 04:06 AM
    Thread: Is it necessary to pass value of 'self' ?
Post: RE: Is it necessary to pass value of 'self' ?

@bowlofred, @snippsat: You mean to say if I don't instantiate, it is considered STATIC ? Thanks for the answers.
rpk2006 General Coding Help 6 2,752 Jul-13-2020, 03:59 AM
    Thread: Is it necessary to pass value of 'self' ?
Post: Is it necessary to pass value of 'self' ?

I am using VSCode for Python programming. I have two files: (1) pyMain (2) pyTests With this program I am learning to write unit tests using pyTest. [pyMain.py] class Mathematics: def AddNum(se...
rpk2006 General Coding Help 6 2,752 Jul-12-2020, 07:51 PM

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020