test: test buildroot read_with_timeout function
- Added a new stage that is stuck in an infinite loop - Added two tests that use this stage and force a timeout
This commit is contained in:
parent
cd8f8681ad
commit
99c739fd60
2 changed files with 50 additions and 0 deletions
20
stages/org.osbuild.test.timeout
Normal file
20
stages/org.osbuild.test.timeout
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
#!/usr/bin/python3
|
||||
"""
|
||||
Test stage that is used for timeout tests
|
||||
"""
|
||||
|
||||
import time
|
||||
import sys
|
||||
|
||||
def main():
|
||||
|
||||
print('Test stage output.')
|
||||
while True:
|
||||
time.sleep(2)
|
||||
|
||||
return 0
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
r = main()
|
||||
sys.exit(r)
|
||||
Loading…
Add table
Add a link
Reference in a new issue