From e74398cda112543aa6f19ed615001976ee89536f Mon Sep 17 00:00:00 2001 From: Elena ``of Valhalla'' Grandi Date: Thu, 25 Mar 2021 17:33:49 +0100 Subject: New command: get-values --- tests/test_commands.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'tests') diff --git a/tests/test_commands.py b/tests/test_commands.py index 92b603f..99cc649 100644 --- a/tests/test_commands.py +++ b/tests/test_commands.py @@ -121,6 +121,19 @@ class testCommands(unittest.TestCase): ) self.assertEqual(streams['stderr'].getvalue(), '') + def test_get_values(self): + args = { + 'collection': self.tmpdir.name, + 'git': True, + 'template': False, + 'query': '*', + 'field': 'position', + } + streams = self._run_command(command.GetValues(), args) + print(streams['stdout'].getvalue()) + self.assertIn('somewhere: 2', streams['stdout'].getvalue()) + self.assertEqual(streams['stderr'].getvalue(), '') + def test_export(self): dest_tmpdir = tempfile.TemporaryDirectory() utils.copytree( -- cgit v1.2.3