Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TST: Revisit xpassed tests and remove xfail from them #7056

Closed
pllim opened this issue Jan 9, 2018 · 1 comment
Closed

TST: Revisit xpassed tests and remove xfail from them #7056

pllim opened this issue Jan 9, 2018 · 1 comment

Comments

@pllim
Copy link
Member

pllim commented Jan 9, 2018

Like #6665 but looks like different tests are affected now. Haven't had time to track down exactly which ones. (Would be easier to run tests locally on master with xpassed handled as failures.)

I set the following in my local copy of setup.cfg in the master checkout:

[pytest]
xfail_strict=true

Then, I ran the tests with --remote-data option and found the following marked as xfail to not be failing anymore:

__________________________ test_transforms_diff[sc1] ___________________________
[XPASS(strict)] 
__________________________ test_transforms_diff[sc3] ___________________________
[XPASS(strict)] 

This is the test function in test_sky_coord_velocities.py:

@pytest.mark.xfail
def test_transforms_diff(sc):
    # note that arguably this *should* fail for the no-distance cases: 3D
    # information is necessary to truly solve this, hence the xfail
    trans = sc.transform_to(PrecessedGeocentric(equinox='B1975'))
    assert isinstance(trans.frame, PrecessedGeocentric)

git blame points to @eteq for that implementation.

Also, as @bsipocz found:

# at the time of this writing, sky offset frames don't support velocities
# TODO: make them actually work
@pytest.mark.xfail
def test_skyoffset_frame(sc):

    sc.skyoffset_frame()

p.s. https://travis-ci.org/astropy/astropy/jobs/332937023 reported 6 xpassed but I only found 2 locally in 3.0RC1. Maybe #7065 would make tracking these down much easier.

@pllim pllim added the testing label Jan 9, 2018
@pllim pllim changed the title Revisit xpassed tests and remove xfail from them TST: Revisit xpassed tests and remove xfail from them Jan 10, 2018
@pllim
Copy link
Member Author

pllim commented Mar 8, 2018

I looked at test_transforms_diff a bit more and suspect that the xpass was introduced back in #6944 where it was first written (see https://travis-ci.org/astropy/astropy/jobs/320521988 L4487-L4488):

astropy/coordinates/tests/test_sky_coord_velocities.py .........x...x... [ 16%]
X...x.x.x...x...X...x                                                    [ 16%]

This is because two of the 4 test cases do have distance and should not have failed. PR forthcoming.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants