Module:Arrowverse redirect category handler/testcases

-- Unit tests for Module:Arrowverse redirect category handler. Click talk page to run tests. local p = require('Module:UnitTests')

function p:test_01_1_testSeriesName_live self:preprocess_equals_many('', {		{"", "Arrowverse" },		{"arrow=yes", "Arrow (TV series)"},		{"flash=yes", "The Flash (2014 TV series)"},		{"constantine=yes", "Constantine (TV series)"},		{"legends=yes", "Legends of Tomorrow"},		{"supergirl=yes", "Supergirl (TV series)"},		{"vixen=yes", "Vixen (web series)"},		{"ray=yes", "Freedom Fighters: The Ray"},		{"batwoman=yes", "Batwoman (TV series)"},		{"black_lightning=yes", "Black Lightning (TV series)"},	}) end

function p:test_01_2_testSeriesName_sandbox self:preprocess_equals_many('', {		{"", "Arrowverse" },		{"arrow=yes", "Arrow (TV series)"},		{"flash=yes", "The Flash (2014 TV series)"},		{"constantine=yes", "Constantine (TV series)"},		{"legends=yes", "Legends of Tomorrow"},		{"supergirl=yes", "Supergirl (TV series)"},		{"vixen=yes", "Vixen (web series)"},		{"ray=yes", "Freedom Fighters: The Ray"},		{"batwoman=yes", "Batwoman (TV series)"},		{"black_lightning=yes", "Black Lightning (TV series)"},	}) end

function p:test_02_1_getSeriesList_live self:preprocess_equals('', 'table') end

function p:test_02_2_getSeriesList_sandbox self:preprocess_equals('', 'table') end

function p:test_03_1_getFranchiseName_live self:preprocess_equals('', 'Arrowverse') end

function p:test_03_2_getFranchiseName_sandbox self:preprocess_equals('', 'Arrowverse') end

function p:test_04_1_redirect_categories_live self:preprocess_equals_many('', {		{"", "R from fictional character, R to section, R with possibilities, R printworthy"},		{"arrow=yes|flash=yes", "Arrow (TV series), The Flash (2014 TV series), Arrowverse, R from fictional character, R to section, R with possibilities, R printworthy"},	}) end

function p:test_04_1_redirect_categories_sandbox self:preprocess_equals_many('', {		{"", "R from fictional character, R to section, R with possibilities, R printworthy"},		{"arrow=yes|flash=yes", "Arrow (TV series), The Flash (2014 TV series), Arrowverse, R from fictional character, R to section, R with possibilities, R printworthy"},	}) end

return p