Belle II Software
development
Toggle main menu visibility
Main Page
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
z
Variables
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
v
w
x
z
Typedefs
a
b
c
d
e
g
i
k
l
m
n
p
r
s
t
u
v
w
Enumerations
Enumerator
c
d
f
p
t
v
Classes
Class List
Class Hierarchy
Class Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
Enumerations
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
Enumerator
a
b
c
d
e
f
g
h
k
l
m
n
o
p
r
s
t
u
v
w
z
Related Functions
b
c
d
g
i
o
r
s
t
Files
File List
File Members
All
Functions
Typedefs
Macros
test_tag_merge.py
1
8
9
'''
10
Test for checking if b2conditionsdb-tag-merge behaves as expted:
11
- highest priority to the first tag in the list;
12
- within the same tag, highest priority to the payloads with the highest revision number.
13
'''
14
15
16
import
subprocess
17
18
import
conditions_db
as
cdb
19
20
21
if
__name__ ==
'__main__'
:
22
23
tags = [
'main_tag_merge_test_1'
,
'main_tag_merge_test_2'
,
'main_tag_merge_test_3'
]
24
final_tag =
'main_tag_merge_test_0'
25
26
db = cdb.ConditionsDB()
27
28
for
tag
in
tags:
29
payloads = db.get_all_iovs(globalTag=tag)
30
payloads.sort(key=
lambda
p: p.iov)
31
32
for
payload
in
payloads:
33
print(f
' {payload.name} r{payload.revision} {payload.iov}'
)
34
35
subprocess.check_call([
'b2conditionsdb-tag-merge'
,
'-o'
, final_tag,
'--dry-run'
] + tags)
36
37
subprocess.check_call([
'b2conditionsdb-tag-merge'
,
'-o'
, final_tag,
'--dry-run'
,
'--run-range'
,
'5'
,
'0'
,
'5'
,
'300'
] + tags)
framework
tests
test_tag_merge.py
Generated on Wed Apr 9 2025 02:41:03 for Belle II Software by
1.9.6