404

[ Avaa Bypassed ]




Upload:

Command:

elspacio@3.12.76.168: ~ $
import unittest

from tap.directive import Directive


class TestDirective(unittest.TestCase):
    """Tests for tap.directive.Directive"""

    def test_finds_todo(self):
        text = "ToDo This is something to do."
        directive = Directive(text)

        self.assertTrue(directive.todo)

    def test_finds_simplest_todo(self):
        text = "TODO"
        directive = Directive(text)

        self.assertTrue(directive.todo)

    def test_todo_has_boundary(self):
        """TAP spec indicates TODO directives must be on a boundary."""
        text = "TODO: Not a TODO directive because of an immediate colon."
        directive = Directive(text)

        self.assertFalse(directive.todo)

    def test_finds_skip(self):
        text = "Skipping This is something to skip."
        directive = Directive(text)

        self.assertTrue(directive.skip)

    def test_finds_simplest_skip(self):
        text = "SKIP"
        directive = Directive(text)

        self.assertTrue(directive.skip)

    def test_skip_at_beginning(self):
        """Only match SKIP directives at the beginning."""
        text = "This is not something to skip."
        directive = Directive(text)

        self.assertFalse(directive.skip)

Filemanager

Name Type Size Permission Actions
__pycache__ Folder 0755
__init__.py File 71 B 0644
factory.py File 1.05 KB 0644
run.py File 456 B 0644
test_adapter.py File 1.84 KB 0644
test_directive.py File 1.2 KB 0644
test_formatter.py File 601 B 0644
test_line.py File 1.2 KB 0644
test_loader.py File 3.66 KB 0644
test_main.py File 1.96 KB 0644
test_parser.py File 16.24 KB 0644
test_result.py File 3.4 KB 0644
test_rules.py File 2.81 KB 0644
test_runner.py File 3.32 KB 0644
test_tracker.py File 10.91 KB 0644
testcase.py File 222 B 0644