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

Fix output of figure tests being put in temp dir #2658

Merged
merged 2 commits into from Jun 15, 2018

Conversation

Projects
None yet
4 participants
@Cadair
Copy link
Member

commented Jun 15, 2018

When running the tests with setup.py test the figure images would be put in the temp dir with the install of SunPy and then immediately deleted.
This adds the configuration at the various layers needed to pass through the directory in which setup.py was run.

closes #2653

Fix output of figure tests being put in temp dir
When running the tests with setup.py test the figure images would be put
in the temp dir with the install of SunPy and then immediately delted.
This adds the configuration at the various layers needed to pass through
the directory in which setup.py was run.

@Cadair Cadair requested review from nabobalis and dstansby Jun 15, 2018

@pep8speaks

This comment has been minimized.

Copy link

commented Jun 15, 2018

Hello @Cadair! Thanks for updating the PR.

Line 75:101: E501 line too long (101 > 100 characters)

Comment last updated on June 15, 2018 at 10:28 Hours UTC
@sunpy-bot

This comment has been minimized.

Copy link

commented Jun 15, 2018

Thanks for the pull request @Cadair! Everything looks great!

@Cadair Cadair added the Tests label Jun 15, 2018

@Cadair Cadair added this to the 1.0 milestone Jun 15, 2018

@Cadair Cadair added the [BugFix] label Jun 15, 2018


@pytest.fixture(scope='session', autouse=True)
def figure_base_dir(request):
sunpy.tests.helpers.figure_base_dir = request.config.getoption("--figure_dir")

This comment has been minimized.

Copy link
@Cadair

Cadair Jun 15, 2018

Author Member

This is pretty hacky. I for all my searching could not find a better way however.

@dstansby
Copy link
Contributor

left a comment

Looks good to me if someone's checked it works

@Cadair

This comment has been minimized.

Copy link
Member Author

commented Jun 15, 2018

well it worked locally for me, might be worth someone else giving it a run.

@dstansby

This comment has been minimized.

Copy link
Contributor

commented Jun 15, 2018

👍 working for me

@nabobalis

This comment has been minimized.

Copy link
Contributor

commented Jun 15, 2018

Works for me using pytest.

@nabobalis nabobalis merged commit 26f2221 into sunpy:master Jun 15, 2018

10 checks passed

Giles Click details to preview the documentation build
Details
ci/circleci: egg-info-35 Your tests passed on CircleCI!
Details
ci/circleci: egg-info-36 Your tests passed on CircleCI!
Details
ci/circleci: figure-tests-35 Your tests passed on CircleCI!
Details
ci/circleci: html-docs Your tests passed on CircleCI!
Details
codecov/patch Coverage not affected when comparing 3254e95...533771d
Details
codecov/project 83.38% (-0.03%) compared to 3254e95
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
sunpy-bot All checks passed

@Cadair Cadair deleted the Cadair:figure_dir branch Jun 15, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.