Exemple #1
0
def test_method_extname_3():
    ad = AstroData(TESTFILE)
    with pytest.raises(SingleHDUMemberExcept):
        ad.extname()
Exemple #2
0
def test_method_extname_1():
    ad = AstroData(TESTFILE2)      # Single 'SCI' ext
    assert isinstance(ad.extname(), str)
Exemple #3
0
def test_method_extname_2():
    ad = AstroData(TESTFILE2)      
    assert ad.extname() == 'SCI'
Exemple #4
0
def test_method_rename_ext_3():
    ad = AstroData(TESTFILE2)      # Single 'SCI' ext
    ad.rename_ext("FOO")
    assert ad.extname() == "FOO"
Exemple #5
0
def test_method_rename_ext_4():
    ad = AstroData(TESTFILE2)
    ad.rename_ext("FOO", ver=99)
    assert ad.extname() == "FOO"
    assert ad.extver() == 99
Exemple #6
0
def test_method_extname_3():
    ad = AstroData(TESTFILE)
    with pytest.raises(SingleHDUMemberExcept):
        ad.extname()
Exemple #7
0
def test_method_extname_2():
    ad = AstroData(TESTFILE2)
    assert ad.extname() == 'SCI'
Exemple #8
0
def test_method_extname_1():
    ad = AstroData(TESTFILE2)  # Single 'SCI' ext
    assert isinstance(ad.extname(), str)
Exemple #9
0
def test_method_rename_ext_4():
    ad = AstroData(TESTFILE2)
    ad.rename_ext("FOO", ver=99)
    assert ad.extname() == "FOO"
    assert ad.extver() == 99
Exemple #10
0
def test_method_rename_ext_3():
    ad = AstroData(TESTFILE2)  # Single 'SCI' ext
    ad.rename_ext("FOO")
    assert ad.extname() == "FOO"