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

Bump phoenix_test from 0.3.1 to 0.4.2 #1601

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Oct 14, 2024

Bumps phoenix_test from 0.3.1 to 0.4.2.

Changelog

Sourced from phoenix_test's changelog.

0.4.2

Fixes

  • Fix: do not recycle fresh conn. Commit 24192e2

0.4.1

Added

  • Adds select/4 exact_option option. Commit f881da3
  • Copy headers across redirects . Commit 7ad8cb1

Fixes

  • 🛠️ Fix active form vs form data loading . Commit 37302b9
  • Update phx_click? to check for valid JS commands. Commit 0d54b49
  • Deduplicate data passed to FormPayload (multi checkbox fix). Commit e950ae4

0.4.0

Breaking

  • Select options were previously matched inexactly (as a substring match). That made it impossible to differentiate between two options where one was a subset of the other.

    For example, using select(session, "Email", from: "Contact") could not differentiate between the Email and Email and SMS options. Select options are now matched exactly. Commits [dc7ba01] and [e675561].

    This is a technically a bug fix, but it's also a potentially breaking change for existing tests that accidentally relied on that behavior. If you need inexact matches on options, please open an issue describing your use case.

... (truncated)

Commits
  • d3196ce Publish version 0.4.2
  • 24192e2 Fix: do not recycle fresh conn
  • 5b25afc Refactor: move all element-like modules under Element
  • c3c9c87 Publish version 0.4.1
  • 0d54b49 Update phx_click? to check for valid JS commands (#139)
  • e950ae4 Deduplicate data passed to FormPayload (#137)
  • 7df460a Extract payload operations into FormPayload
  • 06e43e9 Move name validation out of FormData parsing
  • ba34d9a Encapsulate FormData data structure
  • b37199d Rename build_data -> build_payload to clarify
  • Additional commits viewable in compare view

Dependabot compatibility score

You can trigger a rebase of this PR by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Note
Automatic rebases have been disabled on this pull request as it has been open for over 30 days.

Bumps [phoenix_test](https://github.com/germsvel/phoenix_test) from 0.3.1 to 0.4.2.
- [Changelog](https://github.com/germsvel/phoenix_test/blob/main/CHANGELOG.md)
- [Commits](germsvel/phoenix_test@v0.3.1...v0.4.2)

---
updated-dependencies:
- dependency-name: phoenix_test
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot added dependencies Pull requests that update a dependency file elixir Pull requests that update Elixir code labels Oct 14, 2024
@nshoes nshoes self-assigned this Oct 31, 2024
@nshoes nshoes force-pushed the dependabot/hex/phoenix_test-0.4.2 branch from b5759b0 to 19c14a1 Compare October 31, 2024 19:32
|> select(
"#{firmware.version} #{firmware.platform} #{firmware.architecture} #{firmware.uuid}",
from: "Firmware version"
)
|> click_button("Create Deployment")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@joshk looking for some direction here before I venture out of this repo for answers. The change I made from fill_in -> select works, but now this test fails on submit:

 1) test new deployment the happy path, with an audit log (NervesHubWeb.Live.Deployments.NewTest)
     test/nerves_hub_web/live/deployments/new_test.exs:9
     ** (ArgumentError) could not find non-disabled input, select or textarea with name "deployment[platform]" within:

         <input class="form-control" id="name_input" name="deployment[name]" type="text"/>
         <input class="form-control" id="tags_input" name="deployment[tags]" type="text" value=""/>
         <select class="form-control" id="firmware_id" name="deployment[firmware_id]" required="required"><option value="">Choose a firmware version</option><option value="1564">1.0.0 taramasalata x86_64 8dc5f02a-298f-5890-bbda-b697d1b88d47</option></select>
         <input class="form-control" id="version_input" name="deployment[version]" type="text" value=""/>

     code: |> click_button("Create Deployment")
     stacktrace:
       (phoenix_live_view 0.20.17) lib/phoenix_live_view/test/live_view_test.ex:1102: Phoenix.LiveViewTest.call/2
       (phoenix_test 0.4.0) lib/phoenix_test/live.ex:328: PhoenixTest.Live.submit_form/4
       test/nerves_hub_web/live/deployments/new_test.exs:32: (test)

Phoenix.LiveViewTest is looking for deployment[platform], but the form element no longer exists because of the logic in deployments/new.html.eex.

Have you seen anything like this before? I have experience with LiveView, but not testing it with phoenix_test. I did verify this broke in 0.4.0 of phoenix_test.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can leave this with me as I was in talks with German (the author of the lib) about the issues I saw with upgrading; I just put this to the side temporarily as I picked up other items.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome! Thank you 🙇

@nshoes nshoes removed their assignment Nov 4, 2024
@nshoes nshoes added the blocked label Nov 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked dependencies Pull requests that update a dependency file elixir Pull requests that update Elixir code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants