summaryrefslogtreecommitdiffstats
path: root/test cases/common/216 custom target input extracted objects/check_object.py
blob: d521b4380649bdd1b0edb54768bc679838dda932 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/usr/bin/env python3

import sys, os

if __name__ == '__main__':
    if len(sys.argv) < 4:
        print(sys.argv[0], 'n output objects...')
        sys.exit(1)
    if len(sys.argv) != int(sys.argv[1]) + 3:
        print(f'expected {sys.argv[1]} objects, got {len(sys.argv) - 3}')
        sys.exit(1)
    for i in sys.argv[3:]:
        print('testing', i)
        if not os.path.exists(i):
            sys.exit(1)
    with open(sys.argv[2], 'wb') as out:
        pass