# Path: blimpy/dice.py
# def cmd_tool(args=None):
# 
# Path: tests/data.py

# 
# Path: tests/data.py



import os
import pytest
from blimpy import dice
from tests.data import voyager_h5
from tests.data import voyager_fil
        dice.cmd_tool(args)

def test_missing_format_type():
    with pytest.raises(SystemExit):
        args = ['-f', voyager_h5, '-b', '8419.24', '-e', '8419.35', '-x']
        dice.cmd_tool(args)

# This section makes sure that the tool can handle various
# file formats without exception.

def test_h5():
    os.chdir(TEST_DATA_DIR)
    args = ['-f', voyager_h5, '-b', '8419.24', '-e', '8419.35', '-x', 'h5', '-o', 'test_dice.h5']
    dice.cmd_tool(args)
    os.chdir(HERE)

def test_h5_no_out_file():
    os.chdir(TEST_DATA_DIR)
    args = ['-f', voyager_h5, '-b', '8419.24', '-e', '8419.35', '-x', 'h5']
    dice.cmd_tool(args)
    os.chdir(HERE)

def test_fil():
    os.chdir(TEST_DATA_DIR)
    args = ['-f', voyager_fil, '-b', '8419.24', '-e', '8419.35', '-x', 'fil', '-o', 'test_dice.fil']
    dice.cmd_tool(args)
    os.chdir(HERE)

def test_fil_no_out_file():
    os.chdir(TEST_DATA_DIR)

# Path: blimpy/dice.py
# def cmd_tool(args=None):
# 
# Path: tests/data.py

# 
# Path: tests/data.py



# Path: tests/test_dice.py
import os
import pytest
from blimpy import dice
from tests.data import voyager_h5
from tests.data import voyager_fil

        dice.cmd_tool(args)

def test_missing_format_type():
    with pytest.raises(SystemExit):
        args = ['-f', voyager_h5, '-b', '8419.24', '-e', '8419.35', '-x']
        dice.cmd_tool(args)

# This section makes sure that the tool can handle various
# file formats without exception.

def test_h5():
    os.chdir(TEST_DATA_DIR)
    args = ['-f', voyager_h5, '-b', '8419.24', '-e', '8419.35', '-x', 'h5', '-o', 'test_dice.h5']
    dice.cmd_tool(args)
    os.chdir(HERE)

def test_h5_no_out_file():
    os.chdir(TEST_DATA_DIR)
    args = ['-f', voyager_h5, '-b', '8419.24', '-e', '8419.35', '-x', 'h5']
    dice.cmd_tool(args)
    os.chdir(HERE)

def test_fil():
    os.chdir(TEST_DATA_DIR)
    args = ['-f', voyager_fil, '-b', '8419.24', '-e', '8419.35', '-x', 'fil', '-o', 'test_dice.fil']
    dice.cmd_tool(args)
    os.chdir(HERE)

def test_fil_no_out_file():
    os.chdir(TEST_DATA_DIR)

    args = ['-f', voyager_fil, '-b', '8419.24', '-e', '8419.35', '-x', 'fil']