Skip to content

Releases: ftes/fluffy

Fluffy 0.6.0

Choose a tag to compare

@ftes ftes released this 01 Oct 13:31
a641937

Added

  • Fluffy.PhoenixTest provides a slim PhoenixTest-style vocabulary (visit, click_link, fill_in, select, check, within, assert_has, assert_path, and friends) over Fluffy sessions from a single import. Unsupported options and combinations raise ArgumentError.
  • open_browser/2 opens an HTML snapshot from any driver for inspecting a test's current page.
  • Independent wait_for/3 and await/1 event waits, pipeable expect_event and assert_event helpers, and persistent on, once, and off listeners. Predicates select events; ordinary ExUnit assertions check the returned values.
  • Live browser frame handles from Event.frame_navigated/1, page/context request and response scopes, and dialog handles with explicit acceptance or dismissal.
  • Download handles expose metadata when downloading starts. Download.read!/2 and Download.save_as!/2 wait for completion; reads retain the default 10 MB limit and saves use bounded memory.

Changed

  • Breaking: replace keyed event captures, callback-style wait_for, captured-result assertion constructors, and Event.navigation with independent waits and ordinary values. Use page URL/status assertions for cross-backend navigation outcomes. See Events and pages for migration examples.
  • Sessions and pages are live handles backed by shared session state. Actions remain visible through existing handles, while page selection stays local to each session handle. Closed pages reject subsequent operations, and session resources close with their owning test process.
  • Form actions accept values implementing String.Chars. The PhoenixTest facade retains its wrapper, scoped operations, and active-form tracking for submit().
  • Require playwright_ex ~> 0.13.0 for synchronous event cleanup and page frame-navigation events.

Fixed

  • Resolve Phoenix :checked selectors and selected-option assertions against current user input as well as server-rendered form state.
  • Keep in-process DOM indexes local to the calling test process to avoid copying them through the session runtime on every operation.
  • File chooser handles retain their source page, reconcile navigation there, and preserve the caller's page selection.
  • Popup events resolve without waiting for loading; subsequent actions and assertions wait for document readiness and LiveView connection.

Fluffy 0.5.1

Choose a tag to compare

@ftes ftes released this 17 Sep 06:48
6f62868

Added

  • new_page/2 creates and activates a named browser page in the existing session.
  • go_back/2 and go_forward/2 navigate browser history, and close_session/1 releases session resources early.
  • hover/3, drag_to/4, and press_sequentially/4 provide native browser interactions with strict locators and navigation reconciliation.
  • Fluffy.Playwright helpers add, query, and clear cookies, and export reusable storage state to a map or JSON file.

Fixed

  • Restore exported browser storage state from string-keyed maps and JSON files.
  • Route page activation through the session's Playwright connection when bringing its tab to the front.

Fluffy 0.5.0

Choose a tag to compare

@ftes ftes released this 16 Sep 16:30
5a73e5f

Added

  • Lazy Playwright frame locators, nested frame scopes, content_frame/1, and Fluffy.FrameLocator.owner/1.
  • Fluffy.OperationError for element-action failures across drivers, carrying backend, driver, operation, locator or file-chooser key, and the original cause.

Changed

  • Browser action failures, including submit and file selection, now preserve native Playwright errors and call logs instead of inferring Fluffy.StrictnessError or Fluffy.ActionabilityError from a later DOM snapshot. Callers rescuing structural errors from public actions should rescue Fluffy.OperationError instead. Static and LiveView preserve structural errors in cause, wrapping only after action retries finish. Assertions remain ExUnit.AssertionError; invalid arguments and unsupported capabilities stay distinct.
  • Browser assertions continue to raise ExUnit.AssertionError, retaining Playwright's received values, timeout details, and call logs. Candidate markup is no longer reconstructed.
  • Require playwright_ex ~> 0.12.0 for locator evaluation and native assertion diagnostics.

Fixed

  • Enforce strict locator resolution for focus, blur, and key presses, including ambiguous iframe owners.