Skip to content

ActiveAdmin resources don't get annotated after migrations #777

Open
@vfonic

Description

@vfonic

Commands

# suppose we have a fictional Post model
$ rails g migration AddReadingTimeToPosts reading_time
$ rails db:migrate

Output

Actual

== 20200312212633 AddReadingTimeToPosts: migrating ==============================
-- add_column(:posts, :reading_time, :string)
   -> 0.0020s
== 20200312212633 AddReadingTimeToPosts: migrated (0.0021s) =====================

Annotated (3): app/models/post.rb, spec/models/posts_spec.rb, spec/factories/posts.rb
config/routes.rb was annotated.

Expected

== 20200312212633 AddReadingTimeToPosts: migrating ==============================
-- add_column(:posts, :reading_time, :string)
   -> 0.0020s
== 20200312212633 AddReadingTimeToPosts: migrated (0.0021s) =====================

Annotated (3): app/admin/post.rb, app/models/post.rb, spec/models/posts_spec.rb, spec/factories/posts.rb
config/routes.rb was annotated.

(The only diff is that it's expected that ActiveAdmin resource gets annotated as well)

Version

  • annotate 3.1.0
  • rails 5.2.4.1
  • ruby 2.6.5

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions