Template:Find sources/top proj/testcases

Introduction and set-up
This introductory section does not include any specific test case; it explains how to run the test cases that follow. These tests depend on using the WikiProjects listed in the Talk header template at the top of an article page, and so they cannot be tested in the normal way on this testcases page.

The test cases can be performed in two ways: In each case, the appropriate article means, an article Talkl page which has (or lacks, depending on the sense of the test) the appropriate WikiProject listings. The individual "test cases" below, rather than executing a test, simply provide a list of appropriate articles that may be plugged into the tests described here.
 * at Special:ExpandTemplates, populating the Context title field with the appropriate article Talk page title
 * in situ tests – in Preview Mode at the Talk pages of the appropriate article

The easier method of the two is probably to use ExpandTemplates:
 * 1) go to Special:ExpandTemplates
 * 2) fill in the   at the top of the form using one of the suggested Talk pages listed at the test cases below
 * 3) paste invocations of the live and sandbox templates, with appropriate params (same params for each)
 * 4) Click [OK] and observe the results.

Example: to perform test B-1, choose an article from the B-1 list, and do this: 
 * 1) paste   into 'Context Title' (Note: this article belongs only to WP:WikiProject Video games.)
 * 2) paste the following text into the input wikitext box:


 * 3. Expected result: because this article is a member of project Medicine, the token 'medicine' is returned.

The other method is an in situ test. All of the 'tests in this section may be performed in situ after the following set-up:
 * 1) make the following throw-away changes to sandboxes to set up the tests:
 * 2) * sync the sandboxes of Talk header and find sources to their respective templates
 * 3) * in Template:Talk header/sandbox, alter the transclusion of to  and purge the page
 * 4) * in Template:Find sources/sandbox, alter the transclusion of to  and purge the page
 * 5) choose a Talk page from one of the test cases below, and note what flavor of find_sources links are found in the Talk_header tempiate
 * 6) edit the Talk page, and change the transclusion of  to  (+ optional params; see individual test cases below)
 * 7) click "Preview" button and observe the "find sources" links that are generated in the Talk header and how they compare with what you noted before
 * 8) if the observed links match the "expected result" given in the test case, it's a "pass", otherwise, a "fail".

Any article Talk page with the correct header and projects may be used for this; the lists in the Test cases defined below contains some suggested Talk pages with the correct WikiProjects on them to perform the test case. After viewing the test case result in Preview mode on the page, cancel out and do not save the altered page.

Smoke test
t.b.a.

B-1 Articles transcluding WikiProject Medicine

 * This test may be performed using ExpandTemplates or in situ testing; see .


 * These test cases represent articles that contain the code ' {{WikiProject Medicine '.
 * Expected result: these test cases should return the token.


 * Talk:Giardiasis
 * Talk:Myelodysplastic syndrome
 * Talk:Amoxicillin
 * Talk:Major depressive disorder

B-2 Articles transcluding WikiProject Medicine via a redirect

 * These test cases represent articles that do not contain the code ' '; rather, they include the Medicine project via one of the redirects..


 * CMedWikiProject 0 transclusions
 * Wikiproject_med 0 transclusions
 * Wikiproject_Med 0 transclusions
 * Wikiproject_medicine 6 transclusions
 * Wikiproject_Medicine > 500 transclusions
 * Wikiproject_Medicines 0 transclusions
 * WP Med 4 transclusions
 * WP Medicine 240 transclusions
 * WP:MED 0 transclusions
 * Wpmed 5 transclusions
 * WPMed 18 transclusions
 * WPMED > 500 transclusions
 * WPMedical 0 transclusions
 * WPMedicine 47 transclusions
 * WPMEDICINE 6 transclusions


 * B-2a - some articles transcluding :


 * This is redirect Template:Wikiproject Medicine, not the WikiProject title (note the lower case 'p').
 * Expected result: these test cases should return the token.


 * Talk:Serpin
 * Talk:Diethyl ether
 * Talk:GNE (gene)
 * Talk:C-KAD
 * Talk:Nephelometry (medicine)
 * Talk:PAIR (puncture-aspiration-injection-reaspiration)
 * Talk:Joint replacement
 * Talk:Percy L. Jones
 * Talk:Hysterectomy Educational Resources and Services (HERS) Foundation
 * Talk:Orthovoltage X-rays
 * Talk:Dysacusis
 * Talk:Amyloid beta
 * Talk:Degenerative disease
 * Talk:Corneal dystrophy
 * Talk:Alpha-synuclein
 * Talk:Canadian model of occupational performance and engagement


 * B-2b - some articles transcluding :


 * This is redirect Template:WPMED
 * Expected result: these test cases should return the token.


 * Talk:Hangover
 * Talk:Tuberculosis
 * Talk:Diagnostic and Statistical Manual of Mental Disorders
 * Talk:Adult T-cell leukemia/lymphoma
 * Talk:Kuru (disease)
 * Talk:Temporomandibular joint dysfunction
 * Talk:Guillain–Barré syndrome
 * Talk:Glossary of diabetes
 * Talk:Dominance (genetics)
 * Talk:Binswanger's disease
 * Talk:Serotonin–norepinephrine reuptake inhibitor
 * Talk:Doctor (title)
 * Talk:Algology (medicine)
 * Talk:Wilms' tumor


 * B-2c - some articles transcluding :


 * This is redirect Template:WP Medicine
 * Expected result: these test cases should return the token.


 * [[Talk:TLR7
 * Talk:Clinistrip
 * Talk:Farr's laws
 * Talk:Nursing Open
 * Talk:Patricia A. Ganz
 * Talk:Platelet-rich fibrin matrix
 * Talk:Otto von Schrön
 * Talk:Phenotype (clinical medicine)
 * Talk:Silver nanoparticle (chemotherapy)
 * Talk:MD&DI
 * Talk:Primary cutaneous diffuse large B-cell lymphoma, leg type


 * B-2d - some articles transcluding :


 * This is redirect Template:Wikiproject Medicine
 * Expected result: these test cases should return the token.


 * Talk:Diethyl ether


 * B-2e - some articles transcluding :


 * This is redirect Template:Wikiproject medicine
 * Expected result: these test cases should return the token.


 * Talk:Skin infection
 * Talk:Vaccine exemption


 * B-2f - some articles transcluding :


 * This is redirect Template:WP Med
 * Expected result: these test cases should return the token.


 * Talk:Leo Galland
 * Talk:Prevalence of rabies


 * B-2g - some articles transcluding :


 * This is redirect Template:WPMed
 * Expected result: these test cases should return the token.


 * Talk:MedicineNet
 * Talk:J147


 * B-2h - some articles transcluding :


 * This is redirect Template:wpmed
 * Expected result: these test cases should return the token.


 * Talk:Microinfarct
 * 


 * B-2i - some articles transcluding :


 * This is redirect Template:WPMedicine
 * Expected result: these test cases should return the token.


 * Talk:Cell damage
 * Talk:Trauma shears


 * B-2j - some articles transcluding :


 * This is redirect Template:WPMEDICINE
 * Expected result: these test cases should return the token.


 * Talk:Urethraplasty
 * Talk:Mayer waves