Dandelion is a fair source project. View the code on Github · See the design guide
Commits on Nov 14, 2026
| d231d12 |
Test the order and ticket exports and who sees emails in them The organisation orders CSV, the event orders CSV and PDF, the event tickets CSV and PDF and Order.generate_csv had no tests. These export as an organisation admin and as an event facilitator, with and without show_emails, and check the email columns (the account's and the ticket's own), the names and the answers to the event's questions, that opted-in orders show their email to the facilitator, and that non-admins are refused. Claude-Session: https://claude.ai/code/session_015HnU1NDCturwP6AwudadRw |
| e472412 |
Test setting up organisations' and gatherings' Stripe webhook endpoints Covers StripeWebhooks#create_stripe_webhook_if_necessary: creating an endpoint for the paid checkout events on the organisation's own key and saving its secret, adding missing event types to an existing endpoint (leaving one with them, or with *, alone), paging through endpoints, clearing a key Stripe refuses, doing nothing outside production, and saving an organisation or gathering (and the edit form) triggering it. Claude-Session: https://claude.ai/code/session_015HnU1P7BmVypLmFFgQVh8a |
| 2e3744d |
Test what each kind of notification says, links to and shows as its icon models/notification.rb was 74% covered, with about 20 kinds never rendered. test/notifications_test.rb creates each the
way the app does (accepting an application, adding a member, leaving, deleting an application, the unadmin and
schedule/unschedule routes, comments on an application and in a team thread, reactions, a completed payment, an item,
an organisation, an order, feedback) and checks its sentence, link and icon. Names with markup, set with set as
sanitize_fields would strip it, come out escaped; a reaction other than Nothing creates interested_in_tactivity any more (Attendance has no notifications), so that test makes one directly. No kind raised or output unescaped HTML. Claude-Session: https://claude.ai/code/session_015HnU1KMrTp1aCTpKLm4kSa |
| 792fc9c |
Test fetching exchange rates, and fall back when Uphold answers with an error status DandelionBank's fetching was untested, as every test converts at fixed rates. New tests in payments/exchange_rates run the real fetching on a bank of their own, its HTTP answered by Faraday's test adapter: Uphold's tickers become mid rates, ignoring other pairs and unknown currencies; rates are fetched again only after an hour; Frankfurter and CoinGecko take over when Uphold fails, skipping zero or missing prices; a CoinGecko failure keeps Frankfurter's rates and is reported; and when everything fails it raises with no rates, or keeps and reports with some. The bank converts with them, through USD, across currencies and for stablecoins. They found that an error status from Uphold (a 503 with a JSON error object) wasn't a Faraday error, so the object was read as tickers and raised TypeError instead of falling back. The connection now raises on error statuses. reported_exceptions moves to ErrorReportingHelpers, shared with the ATProto tests. Claude-Session: https://claude.ai/code/session_015HnU1Nh4h7mc3Foj2VWDiR |
| 0d691a4 |
Test the nightly Stripe subscription reconciliation Account.reconcile_stripe_subscriptions, run by the daily errands, had no tests. Cover asking Stripe for every status with customers expanded, paging, clearing ids of unkept or vanished subscriptions, keeping active/trialing/past_due/unpaid ones, taking the newest kept subscription per email, case-insensitive matching, no rewrite when already right, and customers with no email or no account. Fix: strip the customer's email before matching, as the webhook path (sync_subscription) already does, so " donor@example.com " finds its account. Claude-Session: https://claude.ai/code/session_015HnU1KE1RhMv9F1yieCQBN |
| 09dfb03 |
Test the validation of a ticket's chosen price Pay-what-you-want tickets refuse a price that isn't a finite number or is negative, range tickets clamp theirs into the range, complimentary tickets skip both and fixed-price tickets take their ticket type's price. A purchase with a negative, non-numeric or out-of-range chosen price is refused with no order or tickets left behind. Claude-Session: https://claude.ai/code/session_015HnU1KUqeRLMuy8k4ZRii9 |
| 2c80713 |
Test who mass emails to facilitators, ticket groups and waitlists reach A facilitators mail was never sent in a test. It reaches the subscribed facilitators of the organisation's future events and admins of its activities: to_with_unsubscribes leaves out those unsubscribed from the organisation or from Dandelion, as for the other organisation-wide audiences, so there is no bug. Also sends mails to a ticket group, an event's waitlist and a ticket type's waitlist, checking their recipients and the reason their footer gives, and the footer's fallbacks once the ticket group or ticket type is deleted. Claude-Session: https://claude.ai/code/session_015HnU1MFUns9xJKy49LZjwZ |
| 8bba5d4 |
Measure branch coverage too, and list the files with the most untaken branches in the coverage run's summary: line coverage counts a line like |
| b01cd47 |
Refuse an Ethereum sign-in message other than the one issued, and test what sign-in, MCP, the ticket type waitlist and cookie consent claimed but didn't check: the SIWE callback verified the signature, domain, URI, chain and nonce but not that the message was the one issued, so the signer chose its Expiration Time, or left it out, and the 5-minute expiry did nothing. The issued message is now kept in the session (as /accounts/ethereum takes the template) and the signed one must match it but for the address, or fails with message_mismatch; tests refuse a changed nonce, domain, URI, chain or expiry, no expiry, and the issued message after 6 minutes. A sign in code now lets a session connect a provider at 59 minutes and not at 61; the fake Bluesky server can give a bad token, and sign-in is refused one not DPoP-bound or without the atproto scope, metadata with another issuer or an http endpoint, an unknown handle, a DID with no https PDS and a callback with no code; and signing out other browsers from an email link revokes nothing, while signed in with a code it does. The MCP admin tools are called and checked to write nothing, rather than only for their readOnlyHint; the ticket type waitlist test checks its email goes to that type's waitlist about it, not to another still sold out; and a browser test runs a page as production, where the cookie banner and tags render, and checks the marketing tags run only after Accept all. The tags' own scripts (Facebook, Google Tag Manager, Plausible) are in CdnCache::BLOCKED_URLS, so it never reaches them |
| a9e54c0 |
Remove Hy4 from the opencode reviewers |
| fed0f73 |
Make tests that passed with their feature broken check it: the organisation's Stripe webhook tests stubbed construct_event, so its signature check never ran, and now sign each payload with the endpoint secret, with a test that one signed with another secret or unsigned completes nothing; the boost teaser test's boost started in 2 hours, so wasn't live, and both absence checks ran before the events pagelet loaded; the evergreen tests passed on an Event.new with no organisation or dates, and now start from a reminder or feedback request that's due, make the event evergreen, and check nothing's due or sent even with its dates put back, and that it is once it isn't evergreen; the contributions race gate stubbed find_by, which the webhooks don't call, so the deliveries never overlapped, and now holds both at StripeCheckout.paid_session and checks both reached it; the calendar import Faraday fake only recorded stubbed URLs, so "isn't fetched" couldn't fail, and now records any other before failing it; and "credit is only for the buyer signed in" passed credit: false itself, and now books through OrderBuilder signed out and as someone else, with the buyer's credit untouched. And refuse a message to yourself: only GET /messages/:username redirected, while posting one saved it |
| 040be47 |
Start the session calendar test's event at 10:00, so its session never crosses midnight The event factory starts events at the time of day the test runs, and a session that ends on a later date than it starts gets an all-day calendar entry, so the test failed when run from about 21:40 UTC (20:40 in summer): its hour-long session ran past midnight in Stockholm. Its event now starts at 10:00, whatever the time. |
| 6f74cf2 |
List each test group's time and the slowest test files of every group in the run's summary Each test group uploads the seconds its files took (tmp/file_times.json), and a test-times job after them writes two tables to the run's summary: each group's job and test step times, from the API, and the 15 slowest files of all groups, with the total. The tables each group's job summary had are gone; its log still lists its files' times. |
| 49692b9 |
Print each test file's time, slowest first, in the log and the job's summary The times rake test:parallel splits files by are only in an Actions cache, which can't be downloaded, so the log only showed each process's total. Now each run lists its files' seconds once its processes finish, and on CI adds them to the job's summary as a table. |
| b1f635a |
Request admin pages through Rack for every record, and open each once in the browser test/admin_pages_test.rb took about 167s on CI, the longest file in any group, and as one file it ran in one process, so the integrations group waited on it. Its server errors, statuses and names are what a program sees, so it now requests each admin page through Rack, for every record and both kinds of admin, which catches the pages #315 fixed (checked by undoing those fixes). test/admin_pages_browser_test.rb opens each page once, as a site admin for the bare event, for JavaScript errors and pagelets' scripts, in the general group. Locally they take 25s and 37s, against 88s. The records, routes and paths they share are in test/helpers/admin_pages_helpers.rb. |
| 52a1f87 |
Write each test helper once: merge the copies of the purchase POST, Stripe webhook signing and payloads, Mongo command counting, temp-file uploads, JSON ids and queued-job helpers into shared ones, move helpers only one area used into its module, and check it: test_test_helper_bodies_are_written_once, test_test_helper_modules and Dandelion/TestSharedHelper |
| f0a1ccd |
Run issue-to-pr once per daily bug review issue: the reviews run at the same time, so each review's finish picked up the others' issues opened meanwhile too, and each issue ran twice. A review now takes only the issues with its own title prefix |
| 50e29d6 |
Open pull requests for the daily bug reviews' issues (#317)
Claude-Session: https://claude.ai/code/session_015HnU1M4wXovMzuXHYvGD8u
Claude-Session: https://claude.ai/code/session_015HnU1M4wXovMzuXHYvGD8u
Claude-Session: https://claude.ai/code/session_015HnU1M4wXovMzuXHYvGD8u
Claude-Session: https://claude.ai/code/session_015HnU1M4wXovMzuXHYvGD8u |
| 6ee46d8 |
Make tests that couldn't fail, or checked less than they claimed, check what they say (#316)
The pmails view showed New message whenever Padrino.env was :test, so no test checked the mailgun_enabled? gate or the free gift banner. Creating a pmail now sets the real free gift limit, and a new test checks an organisation past its free gift is asked to link Mailgun. The closed activity signup test now checks the signup happened, and the email change test reads and follows the link in the real confirmation email rather than stubbing the method that sends it. Claude-Session: https://claude.ai/code/session_015HnU1P8Uey1RsDrvVWHGSV
With Mongoid.raise_not_found_error false, reload returns the document even when it's been deleted, so assert record.reload could never fail: the checks that an organisation's admin can't unfollow it, that a forged account_id, follower_id or another group's admin can't remove someone, and that a gathering's only admin can't leave. They now find the record again, and Dandelion/AssertReload flags the pattern. The admin password reset test now also checks the account is signed out, as its name says. Claude-Session: https://claude.ai/code/session_015HnU1P8Uey1RsDrvVWHGSV
The slot reorder checks put the foreign slot where its default order already was, so a broken scope couldn't show; it now sits elsewhere. Adding someone to a team or option is tested from the admin's side, and the routes' marks move there, with the refusals checking their response. A forged account_id posted to organisation unsubscribe is tested. The boost test no longer asserts the flag it sets itself, the revenue sharer cell is checked whole, and claim marks come off tests that don't check them (each claim is still covered elsewhere). Claude-Session: https://claude.ai/code/session_015HnU1P8Uey1RsDrvVWHGSV
The Stripe row splitter tests that expected a row unchanged were what it gives for a row it can't split, so they passed whatever the discounts did; each now has a second ticket type, so the row splits, with the amounts worked out by hand. GoCardless webhooks are signed for real rather than stubbing the signature check, and a wrong secret or another organisation's completes no order. GET /qr, /books/:slug and /films/:slug get tests of their own, rather than marks on tests that only loaded them as images. The check-in link claims are covered by a test where an admin shares the scanner's link and an assistant checks someone in, and the booking tests that only check the Pay button are named for that. Claude-Session: https://claude.ai/code/session_015HnU1P8Uey1RsDrvVWHGSV |
| 89d7152 |
List the organisations and gatherings nobody uses on a Spring clean stats page (/stats/spring_clean), rather than in two console methods that printed them Organisation.spring_clean and Gathering.spring_clean printed names from the console, their destroy commented out, and nothing called them. They now return what they find, which the page lists, oldest first, with who made each and a link to its page, from where an admin can delete it: nothing is deleted on the page. The rules are the same: organisations over a month old with no image and nothing in any association but their organisationships and notifications, and listed gatherings over a month old with only the member who made them and nothing else but their teams and notifications. Each checked every association of every record, a query apiece, which a page can't wait for. SpringCleaning.without_associated (models/concerns/spring_cleaning.rb) asks each association once for all the candidates, matching on type too for polymorphic ones (discount codes, notifications, affiliate orders, photos), and gatherings' one member is counted in one aggregation. |