Exemplo n.º 1
0
    def test_check_company_ok(self):
        company = ' Resultados Digitais S./A. '
        company = SFNL.check_company(company)
        assert (company == 'Resultados Digitais S./A.')

        company = 'Oi! '
        company = SFNL.check_company(company)
        assert (company == 'Oi!')

        company = 'Viva :)'
        company = SFNL.check_company(company)
        assert (company == 'Viva :)')
Exemplo n.º 2
0
    def test_check_company_not_ok(self):
        company = 12345
        try:
            company = SFNL.check_company(company)
            raise AssertionError()
        except Exception as invalid:
            print(invalid)

        company = ' 12345 '
        try:
            company = SFNL.check_company(company)
            raise AssertionError()
        except Exception as invalid:
            print(invalid)

        company = ''
        try:
            company = SFNL.check_company(company)
            raise AssertionError()
        except Exception as invalid:
            print(invalid)