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

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

src/f/t/ftw.bridge.client-1.0.8/ftw/bridge/client/tests/test_request.py   ftw.bridge.client(Download)
 
        self.assertEqual(
            utility('target-client', 'path/to/@@something'),
            response)
 
 
        self.assertEqual(
            utility('target-client', '/@@something'),
            response)
 
 
        self.assertEqual(
            utility('target-client', '@@something2'),
            response)
 
 
        headers = {'X-CUSTOM-HEADER': 'some data'}
        self.assertEqual(len(headers), 1)
        self.assertEqual(
            utility('target-client', '@@something',

src/f/t/ftw.bridge.client-1.0.8/ftw/bridge/client/tests/test_favorite.py   ftw.bridge.client(Download)
 
        messages = IStatusMessage(self.request).show()
        self.assertEqual(len(messages), 1)
        self.assertEqual(
            messages[0].message,
            u'The page with uml\xe4uts was added to your favorites.')
        self.assertEqual(messages[0].type,
        view()
 
        self.assertEqual(self.request.response.headers.get('location'),
                         self.page.absolute_url())
 
 
        messages = IStatusMessage(self.request).show()
        self.assertEqual(len(messages), 1)
        self.assertEqual(messages[0].message,
                         u'The target service is currently in ' + \

src/f/t/ftw.bridge.client-1.0.8/ftw/bridge/client/tests/test_watch_action_view.py   ftw.bridge.client(Download)
        view = getMultiAdapter((context, request), name='watch')
        view()
        self.assertEqual(request.response.headers.get('location'),
                         referer_url)
 
        messages = IStatusMessage(request).show()
        self.assertEqual(len(messages), 1)
        self.assertEqual(messages[0].message,
        view = getMultiAdapter((context, request), name='watch')
        view()
        self.assertEqual(request.response.headers.get('location'),
                         referer_url)
 
        messages = IStatusMessage(request).show()
        self.assertEqual(len(messages), 1)

src/f/t/ftw.bridge.client-1.0.8/ftw/bridge/client/tests/test_tabbed.py   ftw.bridge.client(Download)
        component = queryMultiAdapter((config, request), ITableSource)
        self.assertNotEqual(component, None)
        self.assertEqual(type(component), BridgeCatalogTableSource)
 
    def test_implements_interface(self):
        component = queryMultiAdapter((config, request), ITableSource)
        results = component.search_results(query)
        self.assertEqual(len(results), 2)
 
    def test_search_results_fails_when_wrong_configured(self):

src/f/t/ftw.bridge.client-1.0.8/ftw/bridge/client/tests/test_watcher_ajax_view.py   ftw.bridge.client(Download)
        request.form['path'] = '@@watcher-feed?uid=567891234'
 
        self.assertEqual(watcher.AddWatcherPortlet(portal, request)(), 'OK')
 
    def test_view(self):
                ])
 
        self.assertEqual(json.loads(view()), expected_feed_data)
 
    def test_maintenance_error(self):
        self.assertNotEqual(view, None)
 
        self.assertEqual(view(), '"MAINTENANCE"')
 
    def test_view_does_not_fail_when_no_modified_date_is_passed(self):
        view = queryMultiAdapter((portal, request), name='watcher-load-data')
        self.assertNotEqual(view, None)
        self.assertEqual(type(json.loads(view())), dict)
 

src/f/t/ftw.bridge.client-1.0.8/ftw/bridge/client/tests/test_watcher_portlet_addform.py   ftw.bridge.client(Download)
 
        self.assertEqual(
            self.browser.getControl('Recently modified', index=1).optionValue,
            '/++contextportlets++plone.rightcolumn/+/' +
            'ftw.bridge.client.watcher_portlet')
 
    def test_portlet_addform(self):
        self.assertEqual(
            self.portal.restrictedTraverse(
            '++contextportlets++plone.rightcolumn')
        self.assertEqual(
            mapping.keys(),
            ['title_watcher_portlet'])
        assignment = mapping.get('title_watcher_portlet')
        self.assertEqual(assignment.client_id, u'foo')
        self.assertEqual(assignment.path, u'@@bar?baz=1')