File: assert_file_correct.py

package info (click to toggle)
python-asdf 4.3.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 7,032 kB
  • sloc: python: 24,068; makefile: 123
file content (22 lines) | stat: -rw-r--r-- 458 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import argparse
from pathlib import Path

from common import assert_file_correct


def parse_args():
    parser = argparse.ArgumentParser(description="Confirm that an ASDF file generated by generate_file.py can be read")
    parser.add_argument("filename", help="the filename to test")
    return parser.parse_args()


def main():
    args = parse_args()

    path = Path(args.filename)

    assert_file_correct(path)


if __name__ == "__main__":
    main()