Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c542547 commit c29cd93Copy full SHA for c29cd93
1 file changed
Doc/library/unittest.rst
@@ -127,13 +127,13 @@ Here is a short script to test three functions from the :mod:`random` module::
127
128
def test_choice(self):
129
element = random.choice(self.seq)
130
- self.assertIn(element, self.seq)
+ self.assertTrue(element in self.seq)
131
132
def test_sample(self):
133
with self.assertRaises(ValueError):
134
random.sample(self.seq, 20)
135
for element in random.sample(self.seq, 5):
136
137
138
if __name__ == '__main__':
139
unittest.main()
0 commit comments