def test_dos_only(self):
    ' Test combined spectral plots. '
    os.chdir((REAL_PATH + '/data/dispersion'))
    expected_file = 'K3P-OQMD_4786-CollCode25550_spectral.png'
    if os.path.isfile(expected_file):
        os.remove(expected_file)
    sys.argv = ['dispersion', 'K3P-OQMD_4786-CollCode25550', '--png', '--dos_only', '--figsize', '10', '10']
    errored = False
    try:
        matador.cli.dispersion.main()
    except Exception as exc:
        errored = True
        error = exc
    file_exists = os.path.isfile(expected_file)
    if file_exists:
        os.remove(expected_file)
    os.chdir(ROOT_DIR)
    if errored:
        raise error
    self.assertTrue(file_exists)
Test combined spectral plots.
def test_dos_only(self):
    '  '
    os.chdir((REAL_PATH + '/data/dispersion'))
    expected_file = 'K3P-OQMD_4786-CollCode25550_spectral.png'
    if os.path.isfile(expected_file):
        os.remove(expected_file)
    sys.argv = ['dispersion', 'K3P-OQMD_4786-CollCode25550', '--png', '--dos_only', '--figsize', '10', '10']
    errored = False
    try:
        matador.cli.dispersion.main()
    except Exception as exc:
        errored = True
        error = exc
    file_exists = os.path.isfile(expected_file)
    if file_exists:
        os.remove(expected_file)
    os.chdir(ROOT_DIR)
    if errored:
        raise error
    self.assertTrue(file_exists)