mirror of
https://github.com/searxng/searxng.git
synced 2025-09-10 20:28:25 +02:00
js_variable_to_python: add tests, handle more JS syntax
The tests from chompjs are copied. The comment out tests do not pass. The implementation of js_variable_to_python has been updated: * in the main looop, try to make the four different cases more clear * handle decimal number like "-.5", "5." or "- 5" (without double quote) * the character ` is seen a string delimiter as intended in JS * the identifiers follow JS specification ($, _, letters and numbers)
This commit is contained in:
parent
ec540a967a
commit
72f5e7cfb8
3 changed files with 392 additions and 46 deletions
|
@ -21,3 +21,4 @@ aiounittest==1.4.2
|
|||
yamllint==1.32.0
|
||||
wlc==1.13
|
||||
coloredlogs==15.0.1
|
||||
parameterized==0.9.0
|
Loading…
Add table
Add a link
Reference in a new issue