Skip to content

Add a non-ActiveRecord demo resource - #1001

Draft
tagliala wants to merge 1 commit into
mainfrom
feature/9039-non-activerecord-demo
Draft

Add a non-ActiveRecord demo resource#1001
tagliala wants to merge 1 commit into
mainfrom
feature/9039-non-activerecord-demo

Conversation

@tagliala

@tagliala tagliala commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Summary
Provide a minimal sample in response to the request from Javier Julio.

  • Add a read-only API Posts resource backed by seven in-memory records, without an external API or database changes.
  • Demonstrate title/status filtering, retained filter inputs, Clear Filters, and API-style pagination.
  • Disable unsupported sorting, downloads, comments, batch actions, and Ransack-only active-filter chips.
  • Add model, request, and browser coverage plus usage documentation.

Dependency
Temporarily pin ActiveAdmin to e372fc404d788824c0974894418313849f577a1c from activeadmin/activeadmin#9039. The released beta22 lacks the required fixes. Replace this pin once a release includes them; no monkey patches are added.

Verification

  • Full Rails test suite: 28 tests passing on the latest main base.
  • RuboCop lint-only checks using the installed default configuration: passing. The existing repository RuboCop runner lacks its dependency and configuration.
  • Ruby syntax checks and git diff --check: passing.

AI Disclosure
This minimal implementation was produced by GPT-6 Astra and has not been reviewed or verified by a human. Automated checks do not replace human review; this PR is intentionally a draft.

Refs activeadmin/activeadmin#9039

@codecov

codecov Bot commented Sep 7, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 96.10%. Comparing base (6af3731) to head (4090507).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1001      +/-   ##
==========================================
+ Coverage   94.78%   96.10%   +1.32%     
==========================================
  Files          17       19       +2     
  Lines         115      154      +39     
==========================================
+ Hits          109      148      +39     
  Misses          6        6              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Demonstrate ActiveAdmin's non-ActiveRecord support with a read-only API
Posts resource, filtering, and pagination. Use in-memory data so the demo
needs no external service or database changes.

Pin ActiveAdmin to the upstream PR commit until a release includes the
required fixes. Document the limitation and cover the example with
model, request, and browser tests.

Refs activeadmin/activeadmin#9039
@tagliala
tagliala force-pushed the feature/9039-non-activerecord-demo branch from 9f31502 to 4090507 Compare September 7, 2026 08:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant