20 lines
381 B
Python
20 lines
381 B
Python
import os
|
|
import sys
|
|
sys.path.insert(0, os.path.abspath('..'))
|
|
|
|
import pytest
|
|
from py3x.functions import parse_args
|
|
|
|
def test_parse_args_verbose():
|
|
args = parse_args(['-v'])
|
|
assert args
|
|
|
|
def test_parse_args_input():
|
|
args = parse_args(['-i', 'input'])
|
|
assert args
|
|
|
|
def test_parse_args_unused():
|
|
with pytest.raises(SystemExit):
|
|
args = parse_args(['-b'])
|
|
|