예제 #1
0
    def test_is_benchmark_definition_equivalent_all(self):
        layout = BluesteelLayoutEntry.objects.create(name='default-name')
        project = BluesteelProjectController.create_default_project(
            layout, 'project', 0)
        definition = BenchmarkDefinitionController.create_default_benchmark_definition(
        )

        commands = self.get_default_commands()

        self.assertEqual(
            True,
            BenchmarkDefinitionController.is_benchmark_definition_equivalent(
                definition.id, layout.id, project.id, commands))
예제 #2
0
    def test_is_benchmark_definition_equivalent_commands(self):
        layout = BluesteelLayoutEntry.objects.create(name='default-name')
        project = BluesteelProjectController.create_default_project(
            layout, 'project', 0)
        definition = BenchmarkDefinitionController.create_default_benchmark_definition(
        )

        commands = []
        commands.append('command-28')
        commands.append('command-29')
        commands.append('command-30')

        self.assertEqual(
            False,
            BenchmarkDefinitionController.is_benchmark_definition_equivalent(
                definition.id, layout.id, project.id, commands))