Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I think we can have some tests related to dropdown fields like:
1. Check if a dropdown does (not) have the given value(s)
2. Check if the given value(s) is (not) "selected" in the dropdown
The tests should work for both single and multi-select dropdowns.
Any thoughts?
Comment | File | Size | Author |
---|---|---|---|
#4 | manipulate-dropdown-1844656-1.patch | 7.35 KB | sachin2dhoni |
Comments
Comment #1
eliza411 CreditAttribution: eliza411 commentedThose both seem valuable to me ... lots of use cases to see that a choice is presented to some users and not to others.
Comment #2
kssundar CreditAttribution: kssundar commentedUpdating title to better reflect the summary
Comment #3
sachin2dhoni CreditAttribution: sachin2dhoni commentedComment #4
sachin2dhoni CreditAttribution: sachin2dhoni commentedUploading the patch
Comment #5
jhedstromThe feature file should be tagged
@api
, and instead of manually logging the user in, should use theGiven I am logged in as a user with the "administrator" role
step as a background.Since the mink extension uses the 'select' terminology, I'd like to continue using that here instead of 'dropdown'. Also, I wonder if this would be better as a pull request to the mink extension, since there's nothing Drupal-specific in here.
Comment #6
eliza411 CreditAttribution: eliza411 commentedI'm tempted to mark this as closed, won't fix, since it's been hanging around a while and is definitely not Drupal-specific (although it is useful).
I might make the changes jhedstrom suggested and place it as a minkextension request or at least add it to the useful snippet page.