mirror of
https://github.com/arcctgx/ARver
synced 2025-06-06 15:23:37 +02:00
get_releases_by_discid() returns release data in JSON format, so this data can be easily stored in a file. Store information about several discs as test data, and mock get_releases_by_discid() calls to return test release data loaded from JSON files. Change one of the discs used in test: its disc ID began with a period, so its JSON file would be hidden. The new disc has the maximum number of tracks possible in an audio CD (in addition to a pregap). Remove assertion for checking if the returned object is not None. This won't happen if the test is not sending requests to MusicBrainz anymore. Avoiding network overhead makes the test execute almost instantly instead of taking a few seconds. I'm still not sure about the idea of this test - it seems to me that it doesn't actually test very much.
314 lines
No EOL
5.9 KiB
JSON
314 lines
No EOL
5.9 KiB
JSON
{
|
|
"disc": {
|
|
"id": "icmg5lhDisLpCIHbXmBhXUDlN2I-",
|
|
"sectors": "41329",
|
|
"offset-list": [
|
|
150,
|
|
23262
|
|
],
|
|
"offset-count": 2,
|
|
"release-list": [
|
|
{
|
|
"id": "a9f51f88-95db-3686-adda-68e8c203b621",
|
|
"title": "No More Shall We Part",
|
|
"status": "Official",
|
|
"quality": "normal",
|
|
"packaging": "Box",
|
|
"text-representation": {
|
|
"language": "eng",
|
|
"script": "Latn"
|
|
},
|
|
"date": "2001-04-02",
|
|
"country": "GB",
|
|
"release-event-list": [
|
|
{
|
|
"date": "2001-04-02",
|
|
"area": {
|
|
"id": "8a754a16-0027-3a29-b6d7-2b40ea0481ed",
|
|
"name": "United Kingdom",
|
|
"sort-name": "United Kingdom",
|
|
"iso-3166-1-code-list": [
|
|
"GB"
|
|
]
|
|
}
|
|
}
|
|
],
|
|
"release-event-count": 1,
|
|
"barcode": "5016025911646",
|
|
"asin": "B00005AMDQ",
|
|
"cover-art-archive": {
|
|
"artwork": "true",
|
|
"count": "20",
|
|
"front": "true",
|
|
"back": "true"
|
|
},
|
|
"medium-list": [
|
|
{
|
|
"position": "1",
|
|
"format": "CD",
|
|
"disc-list": [
|
|
{
|
|
"id": "2rV5fYWrh_Q5OdFhj2cQ90KxrJg-",
|
|
"sectors": "304849",
|
|
"offset-list": [
|
|
150,
|
|
28232,
|
|
46267,
|
|
81381,
|
|
100016,
|
|
125265,
|
|
151088,
|
|
184855,
|
|
207235,
|
|
231115,
|
|
258746,
|
|
277434
|
|
],
|
|
"offset-count": 12
|
|
},
|
|
{
|
|
"id": "BjuGPxMMz0vaePCLwBspd.vJH1s-",
|
|
"sectors": "304895",
|
|
"offset-list": [
|
|
150,
|
|
28250,
|
|
46287,
|
|
81392,
|
|
100030,
|
|
125287,
|
|
151112,
|
|
184885,
|
|
207260,
|
|
231140,
|
|
258762,
|
|
277452
|
|
],
|
|
"offset-count": 12
|
|
},
|
|
{
|
|
"id": "FQQj.MXRlsPSyF.AaXpWlTheJ4s-",
|
|
"sectors": "304931",
|
|
"offset-list": [
|
|
150,
|
|
28299,
|
|
46339,
|
|
81442,
|
|
100080,
|
|
125337,
|
|
151161,
|
|
184935,
|
|
207312,
|
|
231191,
|
|
258812,
|
|
277503
|
|
],
|
|
"offset-count": 12
|
|
},
|
|
{
|
|
"id": "HjRXCJxLs5EFLRQMkVj_EkyXygo-",
|
|
"sectors": "305079",
|
|
"offset-list": [
|
|
150,
|
|
28294,
|
|
46333,
|
|
81437,
|
|
100074,
|
|
125332,
|
|
151156,
|
|
184930,
|
|
207304,
|
|
231185,
|
|
258807,
|
|
277497
|
|
],
|
|
"offset-count": 12
|
|
},
|
|
{
|
|
"id": "XpTkheONehcz6ck39O3O3Hq.AHo-",
|
|
"sectors": "305080",
|
|
"offset-list": [
|
|
150,
|
|
28283,
|
|
46324,
|
|
81428,
|
|
100064,
|
|
125320,
|
|
151145,
|
|
184920,
|
|
207293,
|
|
231174,
|
|
258795,
|
|
277488
|
|
],
|
|
"offset-count": 12
|
|
},
|
|
{
|
|
"id": "YYEgIL9EWvASwUybT_.AcMKrE.s-",
|
|
"sectors": "305110",
|
|
"offset-list": [
|
|
182,
|
|
28325,
|
|
46365,
|
|
81467,
|
|
100105,
|
|
125362,
|
|
151187,
|
|
184962,
|
|
207335,
|
|
231217,
|
|
258837,
|
|
277527
|
|
],
|
|
"offset-count": 12
|
|
},
|
|
{
|
|
"id": "db4v6RMBl_q5bB5rs5ZHNnm64Xw-",
|
|
"sectors": "303369",
|
|
"offset-list": [
|
|
150,
|
|
28109,
|
|
46013,
|
|
81031,
|
|
99426,
|
|
124438,
|
|
150118,
|
|
183813,
|
|
206123,
|
|
229887,
|
|
257329,
|
|
275956
|
|
],
|
|
"offset-count": 12
|
|
},
|
|
{
|
|
"id": "noPskQ_.CzFuX9eQRlkrsa_Qs74-",
|
|
"sectors": "305077",
|
|
"offset-list": [
|
|
150,
|
|
28292,
|
|
46332,
|
|
81435,
|
|
100072,
|
|
125330,
|
|
151155,
|
|
184930,
|
|
207302,
|
|
231185,
|
|
258805,
|
|
277495
|
|
],
|
|
"offset-count": 12
|
|
}
|
|
],
|
|
"disc-count": 8,
|
|
"track-list": [],
|
|
"track-count": 12
|
|
},
|
|
{
|
|
"position": "2",
|
|
"format": "Enhanced CD",
|
|
"disc-list": [
|
|
{
|
|
"id": "icmg5lhDisLpCIHbXmBhXUDlN2I-",
|
|
"sectors": "41329",
|
|
"offset-list": [
|
|
150,
|
|
23262
|
|
],
|
|
"offset-count": 2
|
|
}
|
|
],
|
|
"disc-count": 1,
|
|
"track-list": [],
|
|
"track-count": 2
|
|
}
|
|
],
|
|
"medium-count": 2
|
|
},
|
|
{
|
|
"id": "f5d0fc2f-1bd2-48f9-8b4a-57896f352361",
|
|
"title": "No More Shall We Part",
|
|
"status": "Official",
|
|
"quality": "normal",
|
|
"packaging": "Jewel Case",
|
|
"text-representation": {
|
|
"language": "eng",
|
|
"script": "Latn"
|
|
},
|
|
"date": "2001",
|
|
"country": "XE",
|
|
"release-event-list": [
|
|
{
|
|
"date": "2001",
|
|
"area": {
|
|
"id": "89a675c2-3e37-3518-b83c-418bad59a85a",
|
|
"name": "Europe",
|
|
"sort-name": "Europe",
|
|
"iso-3166-1-code-list": [
|
|
"XE"
|
|
]
|
|
}
|
|
}
|
|
],
|
|
"release-event-count": 1,
|
|
"barcode": "5016025911646",
|
|
"cover-art-archive": {
|
|
"artwork": "false",
|
|
"count": "0",
|
|
"front": "false",
|
|
"back": "false"
|
|
},
|
|
"medium-list": [
|
|
{
|
|
"position": "1",
|
|
"format": "CD",
|
|
"disc-list": [
|
|
{
|
|
"id": "noPskQ_.CzFuX9eQRlkrsa_Qs74-",
|
|
"sectors": "305077",
|
|
"offset-list": [
|
|
150,
|
|
28292,
|
|
46332,
|
|
81435,
|
|
100072,
|
|
125330,
|
|
151155,
|
|
184930,
|
|
207302,
|
|
231185,
|
|
258805,
|
|
277495
|
|
],
|
|
"offset-count": 12
|
|
}
|
|
],
|
|
"disc-count": 1,
|
|
"track-list": [],
|
|
"track-count": 12
|
|
},
|
|
{
|
|
"position": "2",
|
|
"format": "Enhanced CD",
|
|
"disc-list": [
|
|
{
|
|
"id": "icmg5lhDisLpCIHbXmBhXUDlN2I-",
|
|
"sectors": "41329",
|
|
"offset-list": [
|
|
150,
|
|
23262
|
|
],
|
|
"offset-count": 2
|
|
}
|
|
],
|
|
"disc-count": 1,
|
|
"track-list": [],
|
|
"track-count": 2
|
|
}
|
|
],
|
|
"medium-count": 2
|
|
}
|
|
],
|
|
"release-count": 2
|
|
}
|
|
} |