Skip to content

Allow for customizing Rake tasks. #1428

Open
@mtuchowski

Description

@mtuchowski

RSpec-Core has a RakeTask class we can use to generate Rake tasks and customize them while we at it. RSpec-Rails uses this feature to do just that in rspec.rake and adds tasks for each directory that lives under spec/ dir. While this is great, we loose the ability to customize the tasks, things like name of task or namespace it's defined in are hardcoded in the .rake file.

It would be great if there would be a class that does the same thing as RSpec::Code::RakeTask with the addition of things generated at .rake file. The .rake file would use the class to provide defaults.

This would enable one to wipe the spec task and all derived ones (spec:models, spec:controllers, etc.) from Rake and define them under, say what:ever namespace ;)

Personally, the thing I'm after here is the ability to customize the path to .rspec file without the need to copy-paste said rspec.rake file for its features.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions