1
0
mirror of https://github.com/ytdl-org/youtube-dl synced 2024-12-16 14:36:47 +00:00

Compare commits

..

No commits in common. "65ea8e014aa60b35b4260ff0fcf5d5e7bbcd9e68" and "1e6397b4ac6cc61185e853c0ea26dd2d47eaef37" have entirely different histories.

View File

@ -516,12 +516,11 @@ class TestJSInterpreter(unittest.TestCase):
['t', 'e', 's', 't']) ['t', 'e', 's', 't'])
self._test('function f(){return "t-e-s-t".split(/[es-]+/)}', self._test('function f(){return "t-e-s-t".split(/[es-]+/)}',
['t', 't']) ['t', 't'])
# from MDN: surrogate pairs aren't handled: case 1 fails, and case 2 beats Py3.2 # from MDN: surrogate pairs aren't handled: case 1 fails
if sys.version_info >= (2, 6) and not ((3, 0) <= sys.version_info < (3, 3)): # self._test('function f(){return "😄😄".split(/(?:)/)}',
# self._test('function f(){return "😄😄".split(/(?:)/)}', # ['\ud83d', '\ude04', '\ud83d', '\ude04'])
# ['\ud83d', '\ude04', '\ud83d', '\ude04']) self._test('function f(){return "😄😄".split(/(?:)/u)}',
self._test('function f(){return "😄😄".split(/(?:)/u)}', ['😄', '😄'])
['😄', '😄'])
def test_slice(self): def test_slice(self):
self._test('function f(){return [0, 1, 2, 3, 4, 5, 6, 7, 8].slice()}', [0, 1, 2, 3, 4, 5, 6, 7, 8]) self._test('function f(){return [0, 1, 2, 3, 4, 5, 6, 7, 8].slice()}', [0, 1, 2, 3, 4, 5, 6, 7, 8])