import unittest
from Classes.Gender import Gender


class TestStringMethods(unittest.TestCase):

    def test_RequiredGender(self):
        testrequiredgender = Gender('This scholarship is for females only')
        self.assertIsNotNone(testrequiredgender)
        self.assertEqual(testrequiredgender.getRequiredGender(), ['female'])

    def test_GenderFailure(self):
        failrequiredgender = Gender('There is no gender in this string')
        self.assertIsNotNone(failrequiredgender)
        self.assertEqual(failrequiredgender.getRequiredGender(), [])

    def test_betterGender(self):
        testReq = Gender('This scholarship is for <b>Women </b> only')
        self.assertIsNotNone(testReq)
        self.assertEqual(True, testReq.doesMatchExist())


if __name__ == '__main__':
    unittest.main()

8585d2bcbda82746253fddac2eb5a0c1bcaba300
<mask token>


class TestStringMethods(unittest.TestCase):
    <mask token>

    def test_GenderFailure(self):
        failrequiredgender = Gender('There is no gender in this string')
        self.assertIsNotNone(failrequiredgender)
        self.assertEqual(failrequiredgender.getRequiredGender(), [])

    def test_betterGender(self):
        testReq = Gender('This scholarship is for <b>Women </b> only')
        self.assertIsNotNone(testReq)
        self.assertEqual(True, testReq.doesMatchExist())


<mask token>

<mask token>


class TestStringMethods(unittest.TestCase):

    def test_RequiredGender(self):
        testrequiredgender = Gender('This scholarship is for females only')
        self.assertIsNotNone(testrequiredgender)
        self.assertEqual(testrequiredgender.getRequiredGender(), ['female'])

    def test_GenderFailure(self):
        failrequiredgender = Gender('There is no gender in this string')
        self.assertIsNotNone(failrequiredgender)
        self.assertEqual(failrequiredgender.getRequiredGender(), [])

    def test_betterGender(self):
        testReq = Gender('This scholarship is for <b>Women </b> only')
        self.assertIsNotNone(testReq)
        self.assertEqual(True, testReq.doesMatchExist())


<mask token>

<mask token>


class TestStringMethods(unittest.TestCase):

    def test_RequiredGender(self):
        testrequiredgender = Gender('This scholarship is for females only')
        self.assertIsNotNone(testrequiredgender)
        self.assertEqual(testrequiredgender.getRequiredGender(), ['female'])

    def test_GenderFailure(self):
        failrequiredgender = Gender('There is no gender in this string')
        self.assertIsNotNone(failrequiredgender)
        self.assertEqual(failrequiredgender.getRequiredGender(), [])

    def test_betterGender(self):
        testReq = Gender('This scholarship is for <b>Women </b> only')
        self.assertIsNotNone(testReq)
        self.assertEqual(True, testReq.doesMatchExist())


if __name__ == '__main__':
    unittest.main()

import unittest
from Classes.Gender import Gender


class TestStringMethods(unittest.TestCase):

    def test_RequiredGender(self):
        testrequiredgender = Gender('This scholarship is for females only')
        self.assertIsNotNone(testrequiredgender)
        self.assertEqual(testrequiredgender.getRequiredGender(), ['female'])

    def test_GenderFailure(self):
        failrequiredgender = Gender('There is no gender in this string')
        self.assertIsNotNone(failrequiredgender)
        self.assertEqual(failrequiredgender.getRequiredGender(), [])

    def test_betterGender(self):
        testReq = Gender('This scholarship is for <b>Women </b> only')
        self.assertIsNotNone(testReq)
        self.assertEqual(True, testReq.doesMatchExist())


if __name__ == '__main__':
    unittest.main()
