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

Automatically create a database similar to Rails #18

Open
2 tasks
ilyazub opened this issue Jan 28, 2022 · 0 comments
Open
2 tasks

Automatically create a database similar to Rails #18

ilyazub opened this issue Jan 28, 2022 · 0 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@ilyazub
Copy link
Collaborator

ilyazub commented Jan 28, 2022

It'd be good to automatically set up a database similar to Rails. Rails docs.

In Rails, ActiveRecord::Tasks::DatabaseTasks.reconstruct_from_schema is called inside the ActiveSupport::Testing::Parallelization#after_fork_hook. Ref.

TODO


Originally posted by @pirj in rspec/rspec-rails#2104 (comment):

What was missing (and what Rails provides with its default testing framework):

Active Record automatically handles creating a database

Without createdb myproject2 etc it didn't work. I've seen rails db:test:prepare, but db:create wasn't apparently called.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant