Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2021-11-08 06:26:48 +0300
committerCampbell Barton <ideasman42@gmail.com>2021-11-08 09:00:36 +0300
commit27b37517f8ba113237a7ab58f20eb0c2de40323b (patch)
treef5e92e027c1de7d4f6bd766c41f08f06a548ae6a /tests
parent42df2a7b572e95a0f17542dae01df80fe45f5ee6 (diff)
Cleanup: use static sets
Diffstat (limited to 'tests')
-rw-r--r--tests/performance/api/config.py4
-rw-r--r--tests/performance/api/graph.py2
-rw-r--r--tests/python/modules/mesh_test.py2
3 files changed, 4 insertions, 4 deletions
diff --git a/tests/performance/api/config.py b/tests/performance/api/config.py
index b5e2b390aa3..5e7ee380068 100644
--- a/tests/performance/api/config.py
+++ b/tests/performance/api/config.py
@@ -206,7 +206,7 @@ class TestConfig:
# Optimization to avoid rebuilds.
revisions_to_build = set()
for entry in entries:
- if entry.status in ('queued', 'outdated'):
+ if entry.status in {'queued', 'outdated'}:
revisions_to_build.add(entry.git_hash)
self.queue.has_multiple_revisions_to_build = len(revisions_to_build) > 1
@@ -260,7 +260,7 @@ class TestConfig:
entry.executable = executable
entry.benchmark_type = self.benchmark_type
entry.date = date
- if entry.status in ('done', 'failed'):
+ if entry.status in {'done', 'failed'}:
entry.status = 'outdated'
else:
# Add new entry if it did not exist yet.
diff --git a/tests/performance/api/graph.py b/tests/performance/api/graph.py
index c7d3c5043ec..b04cd367449 100644
--- a/tests/performance/api/graph.py
+++ b/tests/performance/api/graph.py
@@ -21,7 +21,7 @@ class TestGraph:
queue = TestQueue(json_filepath)
for entry in queue.entries:
- if entry.status in ('done', 'outdated'):
+ if entry.status in {'done', 'outdated'}:
device_name = entry.device_name + " (" + entry.device_type + ")"
if device_name in devices.keys():
devices[device_name].append(entry)
diff --git a/tests/python/modules/mesh_test.py b/tests/python/modules/mesh_test.py
index 4cf545d3292..3cee4d88498 100644
--- a/tests/python/modules/mesh_test.py
+++ b/tests/python/modules/mesh_test.py
@@ -113,7 +113,7 @@ class OperatorSpecEditMode:
"""
self.operator_name = operator_name
self.operator_parameters = operator_parameters
- if select_mode not in ['VERT', 'EDGE', 'FACE']:
+ if select_mode not in {'VERT', 'EDGE', 'FACE'}:
raise ValueError("select_mode must be either {}, {} or {}".format('VERT', 'EDGE', 'FACE'))
self.select_mode = select_mode
self.selection = selection