Module:OSM/testcases

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

function p:test_etym self:preprocess_equals('', "Map", {nowiki = false}) self:preprocess_equals('', "Streets named after Leuven", {nowiki = false}) self:preprocess_equals('', "http://overpass-turbo.eu/?Q=%5Btimeout%3A20%5D%5Bout%3Ajson%5D%3B%0A%28%0Anode%5B%22name%3Aetymology%3Awikidata%22~%22%28%5E%7C%3B%29%28Q13104397%29%28%3B%7C%24%29%22%5D%3B%0Away%5B%22name%3Aetymology%3Awikidata%22~%22%28%5E%7C%3B%29%28Q13104397%29%28%3B%7C%24%29%22%5D%3B%0Arelation%5B%22name%3Aetymology%3Awikidata%22~%22%28%5E%7C%3B%29%28Q13104397%29%28%3B%7C%24%29%22%5D%3B%0A%3E%3E%3B%0A%29%3B%0Aout%20geom%3B%0A%7B%7Bstyle%3A%0Anode%20%5Bname%3Aetymology%3Awikidata%5D%7B%0A%20%20text%3A%20name%3B%0A%20%20icon-width%3A%2032%3B%7D%0A%7D%7D%0A&R", {nowiki = false}) end

function p:test_wd self:preprocess_equals('', "Vresse and Florenville", {nowiki = false}) self:preprocess_equals('', "Church of Vresse", {nowiki = false}) self:preprocess_equals('', "Cemetery of Arlon on a map", {nowiki = false}) end function p:test_subject self:preprocess_equals('', "Tombstone of Guido Gezelle", {nowiki = false}) end function p:test_subject self:preprocess_equals('', "Statues of Ernest Claes", {nowiki = false}) end function p:test_brand self:preprocess_equals("", "Toon vestigingen op een kaart", {nowiki = false}) self:preprocess_equals("", "Show locations on map", {nowiki = false}) end function p:test_pt self:preprocess_equals('', "De Lijn 352 on map", {nowiki = false}) end

return p