Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(29)  |  Call(26)  |  Derive(0)  |  Import(3)

src/f/t/ftw.lawgiver-1.2.2/ftw/lawgiver/wdl/parser.py   ftw.lawgiver(Download)
from ftw.lawgiver.exceptions import ParsingError
from ftw.lawgiver.wdl.interfaces import IWorkflowSpecificationParser
from ftw.lawgiver.wdl.specification import Specification
from ftw.lawgiver.wdl.specification import Status
from ftw.lawgiver.wdl.specification import Transition
                    worklist_viewers.append(item)
 
        specargs['states'][title] = Status(title, statements,
                                           role_inheritance,
                                           worklist_viewers)

src/f/t/ftw.lawgiver-1.2.2/ftw/lawgiver/tests/test_generator_unit.py   ftw.lawgiver(Download)
from ftw.lawgiver.tests.base import BaseTest
from ftw.lawgiver.wdl.specification import Specification
from ftw.lawgiver.wdl.specification import Status
from ftw.lawgiver.wdl.specification import Transition
from ftw.testing import ComponentRegistryLayer
    def test_simple_workflow(self):
        spec = Specification(title='Example Workflow',
                             description='the Description',
                             initial_status_title='Foo')
        spec.states['Foo'] = Status('Foo', [])
    def test_multi_word_utf8_status_titles(self):
        status_title = 'Hello W\xc3\xb6rld'
        spec = Specification(title='W\xc3\xb6rkflow',
                             initial_status_title=status_title)
        spec.states[status_title] = Status(status_title, [])
    def test_workflow_with_transitions(self):
        spec = Specification(title='WF',
                             initial_status_title='Foo')
        foo = spec.states['Foo'] = Status('Foo', [])
        bar = spec.states['Bar'] = Status('Bar', [])

src/f/t/ftw.lawgiver-1.2.2/ftw/lawgiver/tests/test_wdl_specificaiton.py   ftw.lawgiver(Download)
from ftw.lawgiver.wdl.specification import Specification
from ftw.lawgiver.wdl.specification import Status
from ftw.lawgiver.wdl.specification import Transition
from ftw.lawgiver.wdl.interfaces import ISpecification
from ftw.lawgiver.wdl.interfaces import IStatus
    def test_VALIDATION_visible_roles_must_be_in_role_mapping(self):
        obj = Specification('My Workflow',
                            initial_status_title='Private',
                            states={'Private': Status('Private', [])},
                            role_mapping={'editor-in-chief': 'Reviewer'},
    def test_string_repr(self):
        obj = Status('Private', [])
        self.assertEquals(unicode(obj),
                          u'<Status "Private">')
 
    def test_string_repr(self):
        private = Status('Private', [])
        public = Status('Public', [])
        obj = Transition('publish', private, public)
        self.assertEquals(unicode(obj),