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

All Samples(16)  |  Call(16)  |  Derive(0)  |  Import(0)

src/f/t/ftw.lawgiver-1.2.2/ftw/lawgiver/tests/test_generator_unit.py   ftw.lawgiver(Download)
            generator('example-workflow', spec)
 
        self.assertEquals('Action "bar" is neither action group nor transition.',
                          str(cm.exception))
 
 
        self.assertEquals(
            {'wf--STATUS--private': 'Private',
             'wf--STATUS--published': 'Published',
             'wf--TRANSITION--publish--private_published': 'publish',
 
        self.assertEquals(
            ['wf--STATUS--private',
             'wf--STATUS--published'],
 

src/f/t/ftw.lawgiver-1.2.2/ftw/lawgiver/tests/test_actiongroups.py   ftw.lawgiver(Download)
 
        registry = self.get_registry()
        self.assertEquals(set(registry._permissions.keys()),
                          set(['Access contents information',
                               'View']))
        registry = self.get_registry()
        self.assertEquals(
            {None: set([u'Access contents information', u'View']),
             u'foo': set([u'List folder contents'])},
 
 
        self.assertEquals(
            sorted(['Access contents information', 'View']),
            sorted(registry._permissions.keys()),
 

src/f/t/ftw.lawgiver-1.2.2/ftw/lawgiver/tests/test_collector.py   ftw.lawgiver(Download)
        self.map_permissions(['Add portal content'], 'edit')
 
        self.assertEquals({'edit': ['Add portal content'],
                           'view': ['View']},
                          self.collector.get_grouped_permissions('foo'))
    def test_get_grouped_permissions_NON_DEFAULT(self):
        self.register_permissions(**{'zope2.View': 'View'})
        self.map_permissions(['View'], 'view', workflow_name='foo')
 
        self.assertEquals({}, self.collector.get_grouped_permissions('bar'))
 
        self.assertEquals(
            {'edit': ['Add portal content']},
            self.collector.get_grouped_permissions('bar'))
 
        self.map_permissions(['Add portal content'], 'edit')
 
        self.assertEquals({'view': ['View']},
                          self.collector.get_grouped_permissions('bar'))
 
 
        self.assertEquals(
            {'edit': ['Add portal content'],
             'unmanaged': ['Manage properties', 'View']},
            self.collector.get_grouped_permissions('bar', unmanaged=True))