Problem/Motivation
In Drupal10, the URL to edit file field details has changed slightly,
From:
admin/structure/types/manage/[nodeType]/fields/node.[nodeType].[fieldName]/storage
To:
admin/structure/types/manage/[nodeType]/fields/node.[nodeType].[fieldName]
Because of that URL change, the automated test suite now produces several related failures.
Additionally, the t() function returns a TranslateableMarkup object instead of a string, which causes many failures in the test suite. Since these tests are not for the translation service, they should be removed (following the lead of the Address module on this).
Steps to reproduce
Install the module on a fresh D10 site and run the automated test suite.
Proposed resolution
Attached patch changes the URL for file field edit details, and removes t() from tests where it causes errors. It also updates the submit button text to match current text in core, as well as adjusts the field identifiers where needed.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 3442719-test-love.patch | 3.7 KB | rschwab |
Issue fork filefield_sources-3442719
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
rschwab commentedComment #3
rschwab commentedComment #4
gnugetHi @rschwab.
It seems that your patch cannot be applied using the dev version of the module.
Not sure why.
Comment #5
rschwab commentedI'm not sure why either. It works for me on a fresh pull:
Comment #7
gnugetI create a merge request because the DrupalCi does not allow me to see the console output anymore, and it is hard to check why it is failing.
Here the pipeline, it seems that some tests are still failing, those are expected to fail or with your current patch all the tests should pass?
https://git.drupalcode.org/project/filefield_sources/-/jobs/1423706
David.
Comment #8
rschwab commentedYes these test failures are fixed elsewhere. Here's the links in error order:
Comment #10
gnuget