This is a collection of unit test procedures for edit filters.

New user changing or removing images

edit

Positives

edit

Test 1

edit
  1. Create a page with code [[Image:Example.jpg]] Lorem ipsum dolor sit amet
  2. Remove the image
  3. Assert a match

Test 2

edit
  1. Create a page with code Lorem ipsum dolor sit amet [[Image:Example.jpg]]
  2. remove the image
  3. Assert a match

Test 3

edit
  1. Create a page with code [[Image:Example.jpg]] Lorem ipsum dolor sit amet
  2. Change the page to [[Image:Example2.jpg]] Lorem ipsum dolor sit amet
  3. Assert a match

Test 4

edit
  1. Create a page with code
 {{infobox musical artist
 |name = John Doe
 |img = No male portrait.svg
 }}
  1. Change the page to
 {{infobox musical artist
 |name = John Doe
 }}
  1. Assert a match

Test 5

edit
  1. Create a page with code
 {{Infobox President
 |name = John Doe
 |image = No male portrait.svg
 }}
  1. Change the page to
 {{infobox musical artist
 |name = John Doe
 }}
  1. Assert a match

Test 6

edit
  1. Create a page with code [[File:Example.jpg]] Lorem ipsum dolor sit amet
  2. Remove the image
  3. Assert a match

Negatives

edit

Test 1

edit
  1. Create a page with code [[File:Example.jpg]] Lorem ipsum dolor
  2. Change the page to [[File:Example.jpg]] sit amet
  3. Assert no match

Test 2

edit
  1. Create a page with code
 {{Infobox President
 |name = John Doe
 |image = No male portrait.svg
 }}
  1. Change the page to
 {{Infobox President
 |name = Jane Doe
 |image = No male portrait.svg
 }}