changeset 4059e9f8d6f0 in sao:5.6
details: https://hg.tryton.org/sao?cmd=changeset;node=4059e9f8d6f0
description:
        Returns an Array with the statements for PYSON string of And/Or

        issue9722
        review300711002
        (grafted from e3d683dfad4661f290279913f3d2b0e7492c2779)
diffstat:

 src/pyson.js |  2 +-
 tests/sao.js |  4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diffs (33 lines):

diff -r 2c343669a5a7 -r 4059e9f8d6f0 src/pyson.js
--- a/src/pyson.js      Sun Oct 18 15:58:43 2020 +0200
+++ b/src/pyson.js      Wed Oct 21 23:15:18 2020 +0200
@@ -285,7 +285,7 @@
             return ['boolean'];
         },
         __string_params__: function() {
-            return this._statements;
+            return [this._statements];
         }
     });
 
diff -r 2c343669a5a7 -r 4059e9f8d6f0 tests/sao.js
--- a/tests/sao.js      Sun Oct 18 15:58:43 2020 +0200
+++ b/tests/sao.js      Wed Oct 21 23:15:18 2020 +0200
@@ -253,7 +253,7 @@
         QUnit.strictEqual(new Sao.PYSON.Decoder().decode(eval_), false,
                 'decode(And([false, false, true]))');
         QUnit.strictEqual(new Sao.PYSON.And([false, true, true]).toString(),
-                "And(false, true, true)");
+                "And([false, true, true])");
     });
 
     QUnit.test('PYSON Or', function() {
@@ -321,7 +321,7 @@
         QUnit.strictEqual(new Sao.PYSON.Decoder().decode(eval_), true,
                 'decode(Or([false, false, true]))');
         QUnit.strictEqual(new Sao.PYSON.Or([false, true, true]).toString(),
-                "Or(false, true, true)");
+                "Or([false, true, true])");
     });
 
     QUnit.test('PYSON Equal', function() {

Reply via email to