Logo
Explore Help
Sign In
davide/palladum-lightning
1
0
Fork 0
You've already forked palladum-lightning
Code Issues Pull Requests Actions 5 Packages Projects Releases Wiki Activity
Files
11974a1169b99c52d9fd69c5d80bbefdd5c42075
palladum-lightning/tests/plugins/utf8.py

15 lines
193 B
Python
Raw Normal View History

pytest: test passing utf8 into and out of plugin JSON. We should be able to pass UTF-8 strings to and from plugins without python turning them into JSON-\u escapes. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2019-03-04 13:30:33 +10:30
#!/usr/bin/env python3
pyln: Migrate remaining uses of the deprecated pylightning module `pylightning` is not much more than an alias for `pyln-client`, so this removes the need to install that as well just to run the tests.
2020-02-11 23:04:21 +01:00
from pyln.client import Plugin
pytest: test passing utf8 into and out of plugin JSON. We should be able to pass UTF-8 strings to and from plugins without python turning them into JSON-\u escapes. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2019-03-04 13:30:33 +10:30
plugin = Plugin()
@plugin.method("utf8")
def echo(plugin, utf8):
assert '\\u' not in utf8
return {'utf8': utf8}
plugin.run()
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.25.3 Page: 1664ms Template: 11ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API