diff options
| author | Muhammad Moinur Rahman <bofh@FreeBSD.org> | 2025-08-27 18:36:12 +0000 |
|---|---|---|
| committer | Dag-Erling Smørgrav <des@FreeBSD.org> | 2025-10-02 07:28:58 +0000 |
| commit | 0a8d8b0c878f85462f52fe5faebfb07678fc2c34 (patch) | |
| tree | 0f70e125055b93632b36645ae65cf006d116fb85 /contrib/libucl/python/tests/test_example.py | |
| parent | 3d91e5d58581e000932854e4acb9cc722f01826a (diff) | |
MFV: libucl: Update to 0.9.2
- Add FREEBSD-upgrade instructions
- Add FREEBSD-Xlist file
- Remove all unnecessary files which are not required for in-tree build
Approved by: bapt
Differential Revision: https://reviews.freebsd.org/D50472
Event: Oslo Hackathon 202508
Sponsored by: The FreeBSD Foundation
(cherry picked from commit 2326db40a1d2dd98631d70aae200ca52575139fb)
Diffstat (limited to 'contrib/libucl/python/tests/test_example.py')
| -rw-r--r-- | contrib/libucl/python/tests/test_example.py | 59 |
1 files changed, 0 insertions, 59 deletions
diff --git a/contrib/libucl/python/tests/test_example.py b/contrib/libucl/python/tests/test_example.py deleted file mode 100644 index f0785531f4e2..000000000000 --- a/contrib/libucl/python/tests/test_example.py +++ /dev/null @@ -1,59 +0,0 @@ -from .compat import unittest -import json -import ucl - -_ucl_inp = ''' -param = value; -section { - param = value; - param1 = value1; - flag = true; - number = 10k; - time = 0.2s; - string = "something"; - subsection { - host = { - host = "hostname"; - port = 900; - } - host = { - host = "hostname"; - port = 901; - } - } -} -''' - -_json_res = { - 'param': 'value', - 'section': { - 'param': 'value', - 'param1': 'value1', - 'flag': True, - 'number': 10000, - 'time': '0.2s', - 'string': 'something', - 'subsection': { - 'host': [ - { - 'host': 'hostname', - 'port': 900, - }, - { - 'host': 'hostname', - 'port': 901, - } - ] - } - } -} - -class TestExample(unittest.TestCase): - def test_example(self): - # load in sample UCL - u = ucl.load(_ucl_inp) - - # Output and read back the JSON - uj = json.loads(json.dumps(u)) - - self.assertEqual(uj, _json_res) |
