MCPcopy Create free account
hub / github.com/boostorg/build / build_once

Function build_once

v2/test/core_update_now.py:151–194  ·  view source on GitHub ↗

Make sure that if we call UPDATE_NOW with ignore-minus-n, the target gets updated exactly once regardless of previous calls to UPDATE_NOW with -n in effect.

()

Source from the content-addressed store, hash-verified

149
150
151def build_once():
152 """
153 Make sure that if we call UPDATE_NOW with ignore-minus-n, the target gets
154 updated exactly once regardless of previous calls to UPDATE_NOW with -n in
155 effect.
156
157 """
158 t = BoostBuild.Tester(pass_toolset=0, pass_d0=False)
159
160 t.write("file.jam", """\
161actions do-print
162{
163 echo updating $(<)
164}
165
166NOTFILE target1 ;
167ALWAYS target1 ;
168do-print target1 ;
169
170UPDATE_NOW target1 ;
171UPDATE_NOW target1 : : ignore-minus-n ;
172UPDATE_NOW target1 : : ignore-minus-n ;
173
174DEPENDS all : target1 ;
175""")
176
177 t.run_build_system(["-ffile.jam", "-n"], stdout="""\
178...found 1 target...
179...updating 1 target...
180do-print target1
181
182 echo updating target1
183
184...updated 1 target...
185do-print target1
186
187 echo updating target1
188
189updating target1
190...updated 1 target...
191...found 1 target...
192""")
193
194 t.cleanup()
195
196
197def return_status():

Callers 1

core_update_now.pyFile · 0.85

Calls 3

writeMethod · 0.95
run_build_systemMethod · 0.95
cleanupMethod · 0.95

Tested by

no test coverage detected