当前位置: 首页>>代码示例>>Python>>正文


Python AtramhasisView.concept_view方法代码示例

本文整理汇总了Python中atramhasis.views.views.AtramhasisView.concept_view方法的典型用法代码示例。如果您正苦于以下问题:Python AtramhasisView.concept_view方法的具体用法?Python AtramhasisView.concept_view怎么用?Python AtramhasisView.concept_view使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在atramhasis.views.views.AtramhasisView的用法示例。


在下文中一共展示了AtramhasisView.concept_view方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: test_not_found

# 需要导入模块: from atramhasis.views.views import AtramhasisView [as 别名]
# 或者: from atramhasis.views.views.AtramhasisView import concept_view [as 别名]
 def test_not_found(self):
     request = self.request
     request.matchdict['scheme_id'] = 'TREES'
     request.matchdict['c_id'] = '666'
     request.skos_registry = self.regis
     error_raised = False
     try:
         atramhasisview = AtramhasisView(request)
         atramhasisview.concept_view()
     except ConceptNotFoundException as e:
         error_raised = True
         self.assertIsNotNone(e.__str__())
     self.assertTrue(error_raised)
开发者ID:JDeVos,项目名称:atramhasis,代码行数:15,代码来源:test_views.py

示例2: test_no_type

# 需要导入模块: from atramhasis.views.views import AtramhasisView [as 别名]
# 或者: from atramhasis.views.views.AtramhasisView import concept_view [as 别名]
 def test_no_type(self):
     request = self.request
     request.matchdict['scheme_id'] = 'TREES'
     request.matchdict['c_id'] = '555'
     request.skos_registry = self.regis
     atramhasisview = AtramhasisView(request)
     info = atramhasisview.concept_view()
     self.assertEqual(info.status_int, 500)
开发者ID:JDeVos,项目名称:atramhasis,代码行数:10,代码来源:test_views.py

示例3: test_passing_collection_view

# 需要导入模块: from atramhasis.views.views import AtramhasisView [as 别名]
# 或者: from atramhasis.views.views.AtramhasisView import concept_view [as 别名]
 def test_passing_collection_view(self):
     request = self.request
     request.matchdict['scheme_id'] = 'TREES'
     request.matchdict['c_id'] = '3'
     request.skos_registry = self.regis
     atramhasisview = AtramhasisView(request)
     info = atramhasisview.concept_view()
     self.assertIsNotNone(info['concept'])
     self.assertEqual(info['conceptType'], 'Collection')
     self.assertEqual(info['scheme_id'], 'TREES')
开发者ID:JDeVos,项目名称:atramhasis,代码行数:12,代码来源:test_views.py


注:本文中的atramhasis.views.views.AtramhasisView.concept_view方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。