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


Python TestFactory.import_default_project方法代码示例

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


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

示例1: transactional_setup_method

# 需要导入模块: from tvb.tests.framework.core.factory import TestFactory [as 别名]
# 或者: from tvb.tests.framework.core.factory.TestFactory import import_default_project [as 别名]
 def transactional_setup_method(self):
     """
     Sets up the environment for running the tests;
     creates a test user, a test project, a connectivity and a surface;
     imports a CFF data-set
     """
     self.test_user = TestFactory.create_user("UserRM")
     self.test_project = TestFactory.import_default_project(self.test_user)
     self.connectivity = self._get_entity(Connectivity)
     self.surface = self._get_entity(CorticalSurface)
开发者ID:maedoc,项目名称:tvb-framework,代码行数:12,代码来源:region_mapping_importer_test.py

示例2: transactional_setup_method

# 需要导入模块: from tvb.tests.framework.core.factory import TestFactory [as 别名]
# 或者: from tvb.tests.framework.core.factory.TestFactory import import_default_project [as 别名]
    def transactional_setup_method(self):
        """
        Sets up the environment for running the tests;
        creates a test user, a test project, a connectivity and a surface;
        imports a CFF data-set
        """
        self.test_user = TestFactory.create_user()
        self.test_project = TestFactory.import_default_project(self.test_user)

        self.surface = TestFactory.get_entity(self.test_project, CorticalSurface())
        assert self.surface is not None

        self.region_mapping = TestFactory.get_entity(self.test_project, RegionMapping())
        assert self.region_mapping is not None
开发者ID:maedoc,项目名称:tvb-framework,代码行数:16,代码来源:surfaceviewer_test.py

示例3: transactional_setup_method

# 需要导入模块: from tvb.tests.framework.core.factory import TestFactory [as 别名]
# 或者: from tvb.tests.framework.core.factory.TestFactory import import_default_project [as 别名]
    def transactional_setup_method(self):
        """
        Sets up the environment for running the tests;
        creates a test user, a test project, a connectivity, a cortical surface and a face surface;
        imports a CFF data-set
        """
        self.datatypeFactory = DatatypesFactory()
        self.test_user = self.datatypeFactory.get_user()
        self.test_project = TestFactory.import_default_project(self.test_user)
        self.datatypeFactory.project = self.test_project

        self.connectivity = TestFactory.get_entity(self.test_project, Connectivity())
        assert self.connectivity is not None
        self.face_surface = TestFactory.get_entity(self.test_project, FaceSurface())
        assert self.face_surface is not None
        assert TestFactory.get_entity(self.test_project, EEGCap()) is not None
开发者ID:maedoc,项目名称:tvb-framework,代码行数:18,代码来源:brainviewer_test.py

示例4: transactional_setup_method

# 需要导入模块: from tvb.tests.framework.core.factory import TestFactory [as 别名]
# 或者: from tvb.tests.framework.core.factory.TestFactory import import_default_project [as 别名]
    def transactional_setup_method(self):
        """
        Prepare the database before each test.
        """
        self.import_service = ImportService()
        self.flow_service = FlowService()
        self.project_service = ProjectService()
        self.test_user = TestFactory.create_user()

        self.delete_project_folders()
        result = self.count_all_entities(DataType)
        assert 0 == result, "There should be no data type in DB"
        result = self.count_all_entities(Project)
        assert 0 == result

        self.test_project = TestFactory.import_default_project(self.test_user)
        self.operation = TestFactory.create_operation(test_user=self.test_user, test_project=self.test_project)
        self.adapter_instance = TestFactory.create_adapter()
开发者ID:maedoc,项目名称:tvb-framework,代码行数:20,代码来源:remove_test.py


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