From 035641adb7d0799a5f5a074da41075c34d8edd0f Mon Sep 17 00:00:00 2001
From: Liam Morland <lkmorlan@uwaterloo.ca>
Date: Wed, 9 Feb 2022 13:44:56 -0500
Subject: [PATCH] Issue #3023341: Use File::createFileUrl() in
 FillPdfFormFormTest

---
 tests/src/Functional/FillPdfFormFormTest.php | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/tests/src/Functional/FillPdfFormFormTest.php b/tests/src/Functional/FillPdfFormFormTest.php
index 612ba2a..549d729 100644
--- a/tests/src/Functional/FillPdfFormFormTest.php
+++ b/tests/src/Functional/FillPdfFormFormTest.php
@@ -213,10 +213,8 @@ class FillPdfFormFormTest extends FillPdfUploadTestBase {
     $this->drupalPostForm('admin/content/files', ['edit-filename' => 'fillpdf_test_v3.pdf'], 'Filter');
     $this->assertSession()->elementsCount('css', 'table td.views-field.views-field-filename', 1);
     $this->assertSession()->pageTextContains('Permanent');
-    // @todo Past 8.6.x, use File::load($file_id)->createFileUrl() directly.
-    // See https://www.drupal.org/project/fillpdf/issues/3023341.
-    $file_uri = File::load($file_id)->getFileUri();
-    $this->assertSession()->linkByHrefExists(file_create_url($file_uri));
+    $file_url = File::load($file_id)->createFileUrl();
+    $this->assertSession()->linkByHrefExists($file_url);
 
     // Now go check the File usage screen and see if the FillPdfForm is listed
     // with its canonical link.
-- 
GitLab