From e81fc9b9dbf9d744dcc9fb210e4353a350be1e22 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Wed, 28 Mar 2018 11:01:40 -0400 Subject: Fix jsonb_plpython tests on older Python versions Rewrite one test to avoid a case where some Python versions have output format differences (Decimal('1') vs Decimal("1")). --- contrib/jsonb_plpython/expected/jsonb_plpython.out | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'contrib/jsonb_plpython/expected/jsonb_plpython.out') diff --git a/contrib/jsonb_plpython/expected/jsonb_plpython.out b/contrib/jsonb_plpython/expected/jsonb_plpython.out index bed24010e19..22a7e53b69f 100644 --- a/contrib/jsonb_plpython/expected/jsonb_plpython.out +++ b/contrib/jsonb_plpython/expected/jsonb_plpython.out @@ -6,11 +6,10 @@ LANGUAGE plpythonu TRANSFORM FOR TYPE jsonb AS $$ assert isinstance(val, dict) -plpy.info(sorted(val.items())) +assert(val == {'a': 1, 'c': 'NULL'}) return len(val) $$; SELECT test1('{"a": 1, "c": "NULL"}'::jsonb); -INFO: [('a', Decimal('1')), ('c', 'NULL')] test1 ------- 2 -- cgit v1.2.3