On 03/11/2015 15:26, Luiz Capitulino wrote: > > 1) uglify all tests and make them inconsistent with the QAPI schemas, > > which also uses single-quoted strings > > This doesn't seem hard to fix, we could pre-process the test files, > say in Python, to add the needed escaping.
I'm talking about qtests: qmp_discard_response("{'execute':'change', 'arguments':{" " 'device':'floppy0', 'target': %s, 'arg': 'raw' }}", versus qmp_discard_response("{\"execute\":\"change\", \"arguments\":{" " \"device\":\"floppy0\", \"target\": %s, \"arg\": \"raw\" }}", > > 2) waste time finding a replacement for % interpolation (the best > > replacement here would be to rewrite the tests in Python IMHO, but > > that's not a small ask) > > Is this only used by tests? Can you give an example of this feature? See above. Notice how the %s becomes a JSON string, with automatic backslash escaping. Paolo