1
0
Fork 0

Correctly enforce upper case title IDs

This commit is contained in:
James 2018-01-03 08:19:52 +11:00
parent 2118dc9afd
commit c164bbad69
25 changed files with 59 additions and 62 deletions

View File

@ -15,7 +15,7 @@ region = "eur"
release_date = "2011-11-17"
[[ releases ]]
title = "000400000004e800"
title = "000400000004E800"
region = "jpn"
release_date = "2012-04-25"

View File

@ -5,22 +5,22 @@ needs_system_files = true
needs_shared_font = false
[[ releases ]]
title = "00040000000fc500"
title = "00040000000FC500"
region = "usa"
release_date = "2014-02-07"
[[ releases ]]
title = "00040000000fc600"
title = "00040000000FC600"
region = "eur"
release_date = "2013-12-06"
[[ releases ]]
title = "000400000005e900"
title = "000400000005E900"
region = "jpn"
release_date = "2012-10-11"
[[ testcases ]]
title = "00040000000fc600"
title = "00040000000FC600"
compatibility = "1"
date = "2017-09-07"
version = "HEAD-e0cdaf7"

View File

@ -5,12 +5,12 @@ needs_shared_font = false
game_type = "eshop"
[[ releases ]]
title = "00040000000bb500"
title = "00040000000BB500"
region = "jpn"
release_date = "2012-09-13"
[[ testcases ]]
title = "00040000000bb500"
title = "00040000000BB500"
compatibility = "0"
date = "2017-06-05"
version = "HEAD-8f0a23b"

View File

@ -6,12 +6,12 @@ needs_shared_font = false
game_type = "eshop"
[[releases]]
title = "00040000001bf000"
title = "00040000001BF000"
region = "usa"
release_date = "2017-07-13"
[[testcases]]
title = "00040000001bf000"
title = "00040000001BF000"
compatibility = "4"
date = "2017-10-18"
version = "HEAD-e9d1e8c"

View File

@ -5,12 +5,12 @@ needs_shared_font = false
game_type = "eshop"
[[ releases ]]
title = "000400000013bb00"
title = "000400000013BB00"
region = "all"
release_date = "2015-05-31"
[[ testcases ]]
title = "000400000013bb00"
title = "000400000013BB00"
compatibility = "1"
date = "2017-06-08"
version = "HEAD-8c22334"

View File

@ -4,12 +4,12 @@ needs_system_files = false
needs_shared_font = false
[[ releases ]]
title = "000400000017d800"
title = "000400000017D800"
region = "jpn"
release_date = "2015-12-17"
[[ testcases ]]
title = "000400000017d800"
title = "000400000017D800"
compatibility = "0"
date = "2017-06-10"
version = "HEAD-8f0a23b"

View File

@ -4,12 +4,12 @@ needs_system_files = false
needs_shared_font = true
[[releases]]
title = "00040000001af800"
title = "00040000001AF800"
region = "eur"
release_date = "2017-07-13"
[[testcases]]
title = "00040000001af800"
title = "00040000001AF800"
compatibility = "1"
date = "2017-09-11"
version = "HEAD-5880771"

View File

@ -5,12 +5,12 @@ needs_shared_font = false
game_type = "eshop"
[[ releases ]]
title = "00040000001b6700"
title = "00040000001B6700"
region = "jpn"
release_date = "2017-01-25"
[[ testcases ]]
title = "00040000001b6700"
title = "00040000001B6700"
compatibility = "0"
date = "2017-06-10"
version = "HEAD-9a8a90b"

View File

@ -5,12 +5,12 @@ needs_system_files = false
needs_shared_font = false
[[ releases ]]
title = "0004000000187d00"
title = "0004000000187D00"
region = "usa"
release_date = "2016-09-01"
[[ testcases ]]
title = "0004000000187d00"
title = "0004000000187D00"
compatibility = "4"
date = "2017-06-05"
version = "HEAD-8f0a23b"

View File

@ -5,12 +5,12 @@ needs_shared_font = false
game_type = "eshop"
[[ releases ]]
title = "00040000000e5d00"
title = "00040000000E5D00"
region = "usa"
release_date = "2013-06-13"
[[ releases ]]
title = "00040000000e9200"
title = "00040000000E9200"
region = "eur"
release_date = "2012-09-06"
@ -20,7 +20,7 @@ region = "jpn"
release_date = "2011-06-27"
[[ testcases ]]
title = "00040000000e9200"
title = "00040000000E9200"
compatibility = "0"
date = "2017-06-05"
version = "HEAD-8f0a23b"

View File

@ -5,12 +5,12 @@ needs_shared_font = false
game_type = "eshop"
[[ releases ]]
title = "00040000000cd400"
title = "00040000000CD400"
region = "usa"
release_date = "2013-07-15"
[[ releases ]]
title = "00040000000cbc00"
title = "00040000000CBC00"
region = "eur"
release_date = "2013-01-24"
@ -20,7 +20,7 @@ region = "jpn"
release_date = "2011-12-28"
[[ testcases ]]
title = "00040000000cbc00"
title = "00040000000CBC00"
compatibility = "0"
date = "2017-06-05"
version = "HEAD-8f0a23b"

View File

@ -5,7 +5,7 @@ needs_shared_font = false
game_type = "eshop"
[[ releases ]]
title = "0004000000101d00"
title = "0004000000101D00"
region = "usa"
release_date = "2013-10-03"
@ -15,7 +15,7 @@ region = "eur"
release_date = "2013-12-14"
[[ releases ]]
title = "00040000000eea00"
title = "00040000000EEA00"
region = "jpn"
release_date = "2013-06-12"

View File

@ -15,7 +15,7 @@ region = "eur"
release_date = "2014-05-22"
[[ releases ]]
title = "000400000010f000"
title = "000400000010F000"
region = "jpn"
release_date = "2013-11-20"

View File

@ -10,7 +10,7 @@ region = "usa"
release_date = "2014-11-13"
[[ releases ]]
title = "000400000014d200"
title = "000400000014D200"
region = "eur"
release_date = "2014-11-13"

View File

@ -5,17 +5,17 @@ needs_shared_font = false
game_type = "eshop"
[[ releases ]]
title = "000400000016ef00"
title = "000400000016EF00"
region = "usa"
release_date = "2015-08-06"
[[ releases ]]
title = "000400000016e800"
title = "000400000016E800"
region = "eur"
release_date = "2015-06-30"
[[ testcases ]]
title = "000400000016ef00"
title = "000400000016EF00"
compatibility = "0"
date = "2017-06-05"
version = "HEAD-8f0a23b"

View File

@ -5,17 +5,17 @@ needs_shared_font = false
game_type = "eshop"
[[ releases ]]
title = "00040000001adb00"
title = "00040000001ADB00"
region = "usa"
release_date = "2016-12-15"
[[ releases ]]
title = "00040000001ad600"
title = "00040000001AD600"
region = "eur"
release_date = "2016-12-22"
[[ testcases ]]
title = "00040000001adb00"
title = "00040000001ADB00"
compatibility = "0"
date = "2017-06-05"
version = "HEAD-8f0a23b"

View File

@ -5,17 +5,17 @@ needs_system_files = false
needs_shared_font = false
[[ releases ]]
title = "00040000000ba800"
title = "00040000000BA800"
region = "usa"
release_date = "2013-03-24"
[[ releases ]]
title = "00040000000ba900"
title = "00040000000BA900"
region = "eur"
release_date = "2013-05-17"
[[ testcases ]]
title = "00040000000ba900"
title = "00040000000BA900"
compatibility = "1"
date = "2017-06-05"
version = "HEAD-8f0a23b"

View File

@ -6,12 +6,12 @@ needs_shared_font = false
game_type = "eshop"
[[ releases ]]
title = "000400000017c100"
title = "000400000017C100"
region = "all"
release_date = "2015-12-02"
[[ testcases ]]
title = "000400000017c100"
title = "000400000017C100"
compatibility = "1"
date = "2017-06-05"
version = "HEAD-8f0a23b"

View File

@ -9,12 +9,12 @@ region = "jpn"
release_date = "2015-11-03"
[[releases]]
title = "0004000000119a00"
title = "0004000000119A00"
region = "usa"
release_date = "2015-11-03"
[[releases]]
title = "000400000012cb00"
title = "000400000012CB00"
region = "eur"
release_date = "2015-11-03"
@ -29,7 +29,7 @@ os = "Windows 7 7601"
author = "flaviculpus"
[[testcases]]
title = "0004000000119a00"
title = "0004000000119A00"
compatibility = "0"
date = "2017-10-24"
version = "HEAD-e9d1e8c"

View File

@ -7,22 +7,22 @@ game_type = "vc"
vc_system = "nes"
[[ releases ]]
title = "0004000000093e00"
title = "0004000000093E00"
region = "jpn"
release_date = "2012-07-25"
[[ releases ]]
title = "0004000000094e00"
title = "0004000000094E00"
region = "usa"
release_date = "2012-12-27"
[[ releases ]]
title = "0004000000094f00"
title = "0004000000094F00"
region = "eur"
release_date = "2012-12-27"
[[ testcases ]]
title = "0004000000093e00"
title = "0004000000093E00"
compatibility = "1"
date = "2017-06-05"
version = "HEAD-8c22334"

View File

@ -1,4 +1,4 @@
title = "World 3-2"
description = "Restore Point at World 3-2 with 5 Lives and 65 Coins, Luigi Game and with Small Fire Luigi"
author = "Clector"
title_id = "0004000000093e00"
title_id = "0004000000093E00"

View File

@ -4,12 +4,12 @@ needs_system_files = false
needs_shared_font = false
[[releases]]
title = "00040000000c8c00"
title = "00040000000C8C00"
region = "usa"
release_date = "2013-10-29"
[[testcases]]
title = "00040000000c8c00"
title = "00040000000C8C00"
compatibility = "5"
date = "2017-08-17"
version = "HEAD-21204ba"

View File

@ -7,22 +7,22 @@ game_type = "vc"
vc_system = "nes"
[[ releases ]]
title = "000400000006e700"
title = "000400000006E700"
region = "jpn"
release_date = "2013-01-01"
[[ releases ]]
title = "000400000006e900"
title = "000400000006E900"
region = "eur"
release_date = "2013-12-26"
[[ releases ]]
title = "000400000006e800"
title = "000400000006E800"
region = "usa"
release_date = "2014-04-17"
[[ testcases ]]
title = "000400000006e700"
title = "000400000006E700"
compatibility = "1"
date = "2017-06-05"
version = "HEAD-8c22334"

View File

@ -7,12 +7,12 @@ game_type = "vc"
vc_system = "gb"
[[ releases ]]
title = "000400000007e700"
title = "000400000007E700"
region = "usa"
release_date = "2011-12-22"
[[ testcases ]]
title = "000400000007e700"
title = "000400000007E700"
compatibility = "1"
date = "2017-06-04"
version = "HEAD-8f0a23b"

View File

@ -201,7 +201,7 @@ function validateTOML(path) {
validateContents(release, "title", field => {
if (field.length !== 16) {
validationError(`Release #${i + 1}: Game title ID has an invalid length`);
} else if (!field.match(/^([a-zA-Z0-9]){16}$/)) {
} else if (!field.match(/^([A-Z0-9]){16}$/)) {
validationError(`Release #${i + 1}: Game title ID is not a hexadecimal ID`);
}
});
@ -225,7 +225,7 @@ function validateTOML(path) {
validateContents(testcase, "title", field => {
if (field.length !== 16) {
validationError(`Testcase #${i + 1}: Game title ID has an invalid length`);
} else if (!field.match(/^([a-zA-Z0-9]){16}$/)) {
} else if (!field.match(/^([A-Z0-9]){16}$/)) {
validationError(`Testcase #${i + 1}: Game title ID is not a hexadecimal ID`);
}
});
@ -261,9 +261,6 @@ function validateTOML(path) {
validationError("Test case dates are not properly sorted in ascending order.");
});
}
/* else {
validationError("No testcases.")
}*/
// We only check these if we have a known test result (we cannot know if a game needs
// resources if it doesn't even run!)
@ -291,7 +288,7 @@ function validateSaveTOML(path) {
validateContents(tomlDoc, "title_id", field => {
if (field.length !== 16) {
validationError(`Game save data: Game title ID has an invalid length`);
} else if (!field.match(/^([a-zA-Z0-9]){16}$/)) {
} else if (!field.match(/^([A-Z0-9]){16}$/)) {
validationError(`Game save data: Game title ID is not a hexadecimal ID`);
}
});