Exemplo n.º 1
0
 def testMakeBarcode(self):
     expected = (
         b'<ns0:metadata xmlns:ns0="http://musicbrainz.org/ns/mmd-2.0#">'
         b'<ns0:release-list><ns0:release ns0:id="trid"><ns0:barcode>12345</ns0:barcode>'
         b'</ns0:release></ns0:release-list></ns0:metadata>')
     xml = mbxml.make_barcode_request({'trid': '12345'})
     self.assertEqual(expected, xml)
Exemplo n.º 2
0
def submit_barcodes(release_barcode):
    """Submits a set of {release_id1: barcode, ...}"""
    query = mbxml.make_barcode_request(release_barcode)
    return _do_mb_post("release", query)
Exemplo n.º 3
0
def submit_barcodes(release_barcode):
    """Submits a set of {release_id1: barcode, ...}"""
    query = mbxml.make_barcode_request(release_barcode)
    return _do_mb_post("release", query)
Exemplo n.º 4
0
 def testMakeBarcode(self):
     expected = (b'<ns0:metadata xmlns:ns0="http://musicbrainz.org/ns/mmd-2.0#">'
                 b'<ns0:release-list><ns0:release ns0:id="trid"><ns0:barcode>12345</ns0:barcode>'
                 b'</ns0:release></ns0:release-list></ns0:metadata>')
     xml = mbxml.make_barcode_request({'trid':'12345'})
     self.assertEqual(expected, xml)
Exemplo n.º 5
0
def submit_barcodes(barcodes):
    """Submits a set of {release1: barcode1, release2:barcode2}

	Must call auth(user, pass) first"""
    query = mbxml.make_barcode_request(barcodes)
    return _do_mb_post("release", query)
Exemplo n.º 6
0
def submit_barcodes(barcodes):
	"""Submits a set of {release1: barcode1, release2:barcode2}

	Must call auth(user, pass) first"""
	query = mbxml.make_barcode_request(barcodes)
	return _do_mb_post("release", query)