Skip to content
This repository was archived by the owner on Nov 11, 2024. It is now read-only.
This repository was archived by the owner on Nov 11, 2024. It is now read-only.

Move test stuff to astropy-helpers if there's a need for it outside astropy-dependents #73

Closed

Description

@eteq

In APE4 and the current master, the test runner and related framework are not in astropy-helpers, but rather in astropy. The justification from @embray in APE4 is that the tests have to be at runtime, so it makes sense to leave it in astropy given that affiliated packages will need it at runtime anyway.

But while working on #72 I realized an issue with that: the test runner and test command are now in separate packages, so they can't be kept in sync. More generally, it's really confusing to figure out how they interplay when they are in different packages. So maybe we should just move all the testing stuff to astropy-helpers too?

cc @astrofrog

Activity

  1. astrofrog commented on Aug 8, 2014

    @astrofrog
    Member

    @eteq - so just to be clear, you are suggesting removing the ability to do astropy.test()?

  2. eteq commented on Aug 8, 2014

    @eteq
    MemberAuthor

    @astrofrog - oh, no, that should still be possible, but it should use code generated by astropy-helpers. I'm thinking something like what we do with version.py, which gets generated at build-time from a single "authoritative" source.

  3. embray commented on Aug 8, 2014

    @embray
    Member

    I think updates that affect both ends of things are infrequent enough that it's not worth the effort.

  4. eteq commented on Aug 8, 2014

    @eteq
    MemberAuthor

    That may well be true... but as far as you're concerned, it's a "not worth the effort" problem rather than "it shouldn't be done" issue, @embray?

  5. embray commented on Aug 8, 2014

    @embray
    Member

    No, not even that. I think if anything the degree to which the setup.py test command needs to be intimately tied to anything in astropy should be lessened. It already depends on astropy to run, so there's no reason it couldn't get most of the information it needs from the installed astropy version as well.

  6. eteq commented on Aug 8, 2014

    @eteq
    MemberAuthor

    I was more thinking about this in the context that astropy-helpers can be used by packages that don't necessarily have an astropy dependency. But those don't exist yet, and perhaps never will, so I guess it's a non-issue right now.

  7. added this to the Future milestone on Aug 11, 2014
  8. changed the title [-]Revisit whether test stuff should be in astropy-helpers[/-] [+]Move test stuff to astropy-helpers if there's a need for it outside astropy-dependents[/+] on Aug 11, 2014
  9. eteq commented on Aug 11, 2014

    @eteq
    MemberAuthor

    @embray - I changed the name and set it to "future" on the theory that this is only worth doing if someone wants to use astropy-helpers but not necessarily have an astropy dependence. Or, if you'd rather keep this repo clean, we can always close it and re-open when it makes sense. Whatever you prefer is fine with me.

  10. embray commented on Aug 11, 2014

    @embray
    Member

    Yeah leaving this open is fine. I think there are some things that could be done here to improve the situation.

  11. eteq commented on Feb 2, 2015

    @eteq
    MemberAuthor

    @embray @astrofrog - I wanted to report an oddity related to this issue that I just encountered. Halotools (which uses the package template) was getting strange errors on travis while trying to run their test suite. It turns out this is because they were using numpy v1.8 for the main part of the test suite, and the conda packages for astropy are numpy 1.9 only after v4.1. So they were getting astropy v4.1, which is incompatible with the current astropy helpers (due to the addition of the repeat keyword for the test runner). Having all of the test stuff in the helpers would get around such versioning issues.

  12. embray commented on Feb 2, 2015

    @embray
    Member

    Interesting...I'll have to take a closer look in a bit. But I feel like when I added the repeat keyword I updated the test runner so that it wouldn't use unsupported arguments. In other words, I thought I made a specific point of addressing this kind of issue.

  13. embray commented on Feb 2, 2015

    @embray
    Member

    @eteq Aha. It appears that the workaround I added for this was only added to the v0.4.x branch on astropy-helpers, and is not in master. I guess the thinking there was that I was going to do something "better" later. But this solution is still better than nothing so I better copy it over...

  14. eteq commented on Feb 3, 2015

    @eteq
    MemberAuthor

    @embray - ok, that sounds good for that particular issue. Can you just ping me when that happens so I know to have halotools update to that version (they can serve as a test case...)?

    The main point of this issue is still relevant because it would have prevented this in the first place. But I guess it's not particularly more urgent now than before...

  15. embray commented on Feb 3, 2015

    @embray
    Member

    It's just too bad I didn't copy the change over--then it would've just worked like I planned =D

  16. embray commented on Nov 20, 2015

    @embray
    Member

    Oops--this was addressed by #184 and related. The test stuff is all back in astropy itself. It could still be split out of astropy too if some package wanted to use it without depending on astropy. But in that case it should be its own entity separate from both astropy and astropy-helpers.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions