Closed (fixed)
Project:
Examples for Developers
Version:
3.x-dev
Component:
Testing Example
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
3 Aug 2019 at 11:24 UTC
Updated:
11 Jun 2020 at 06:59 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
darkdimComment #3
darkdimpatch here
Comment #4
darkdimComment #5
andypostPatch should be applicable with
patch -p1Comment #6
darkdimnew patch, sorry
Comment #7
andypostYou need to move the files as well - out of src to "tests"
Comment #8
darkdimmoved files to tests
Comment #9
mile23It's an example of how to write a Simpletest-based test.
Comment #10
darkdimComment #11
mile23WebTestBase is deprecated, so we don't need any examples of how to make them. https://www.drupal.org/node/3030340
Just remove them.
Comment #12
andypostThis 3 are the only remains, so I removed
NaiveConversionTest.phpand cleaned a bit last 2Comment #13
andypostit may need to check code comment about simpletest but surely that's follow-up
Comment #14
andypostMissed to fix namespace
Comment #15
mile23OK, I got the rescope wrong.
This code, and the module containing it, is instructing you how to convert a WebTestBase test to a BrowserTestBase one.
This is information people will need moving forward.
Whether this information belongs in Examples or not is another story, because it's also present in documentation, linked from the change record: https://www.drupal.org/node/3030340
It's also true that @xjm has said that WTB might become undeprecated before the D9 release, in which case no one needs to learn how to convert WTB tests for another 4 years.
I suggest closing this issue as won't fix. Nothing is actually broken in this documentation-oriented project.
Comment #16
kristen polPer a Slack discussion with Gábor Hojtsy regarding usage of D9 tags (Drupal 9, Drupal 9 compatibility, Drupal 9 readiness, etc.), "Drupal 9 compatibility" should be used for contributed projects that need updating and "Drupal 9" was the old tag for D8 issues before the D9 branch was ready. Doing tag cleanup here based on that discussion.
Comment #17
jungleComment #18
jungleWrapped too early. But can be fixed on committing.
Comment #19
jungleDo not understand @Mile23's comment in #15, I think this patch is good to go.
Comment #20
jungleThe patch kicked the deprecated messages above away.
Comment #21
andypostI think this code needs removal for 9.x because there's no simpletest WTB (WebTestBase) in 9.0
Also there's great docs linked in https://www.drupal.org/node/3030340
I bet on just removal of outdated tests as they were used only to explain conversion process which is documented now
Comment #22
jungleThanks @andypost!
So to remove the two files as well?
Comment #23
jungleAll 3 test files in #20 removed. no interdiff.
Comment #24
vladimirausDrupal rector report:
Drupal check gives me this:
Comment #25
jungleThanks, @VladimirAus! But I think #24 is out of scope here.
Comment #26
vladimirausYou are right @jungle. I was thinking about one issue and reporting another.
Comment #27
pratik_kambleComment #28
vladimiraus* All references for
WebTestBaseare removed.* No dependencies on removed tests found.
Comment #31
jungleThanks @VladimirAus!
Comment #33
jungleAfter discussed with @valthebald on slack. We decided to keep WTB tests in 8.x-1.x as examples still, so reverted the commit.
Comment #34
pratik_kamble