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

Can't change the "test" filename of scripted-test #630

Closed
xuwei-k opened this issue Dec 25, 2012 · 4 comments
Closed

Can't change the "test" filename of scripted-test #630

xuwei-k opened this issue Dec 25, 2012 · 4 comments

Comments

@xuwei-k
Copy link
Member

xuwei-k commented Dec 25, 2012

I want to use different filename. Because Play2.0 has test directory in top level by default.
But current sbt does not configurable test filename.

https://github.com/harrah/xsbt/blob/v0.12.1/scripted/sbt/ScriptedTests.scala#L19
https://github.com/harrah/xsbt/blob/v0.12.1/scripted/sbt/ScriptedTests.scala#L54
https://github.com/harrah/xsbt/blob/v0.12.1/scripted/plugin/ScriptedPlugin.scala#L15-L27

@harrah
Copy link
Member

harrah commented Dec 31, 2012

The scripted framework isn't that sophisticated and I'm not sure how to keep it that way and allow configuring the name. Maybe it could also look for files with some extension. A pull request would be accepted, but perhaps it is reasonable for you to make the Play project a subproject, which wouldn't need a top-level test/? You might be able to override the name of that directory as well (possibly scalaSource in Test).

@harrah
Copy link
Member

harrah commented Oct 9, 2013

@xuwei-k what do you think? Look for an extension as well, like something.test?

@eed3si9n eed3si9n removed this from the 1.0 milestone Aug 8, 2014
@christian-schlichtherle

I've hit the same issue. Why does the code even put some auxiliary file in the same directory as the code under test? If you could change this, it would work no matter what's in the directory.

@eed3si9n
Copy link
Member

eed3si9n commented Jun 13, 2018

Proposed solution:

  1. Look for test.
  2. If it's not found, look for test.script

To potential contributor: The relevant code locations are

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

4 participants