Patchwork [2,of,3] py3: conditionalize json float precision difference in test-debugcommands.t

login
register
mail settings
Submitter Matt Harbison
Date Sept. 29, 2018, 6:20 a.m.
Message ID <e3fa739c298dc8f34d10.1538202008@Envy>
Download mbox | patch
Permalink /patch/35202/
State Accepted
Headers show

Comments

Matt Harbison - Sept. 29, 2018, 6:20 a.m.
# HG changeset patch
# User Matt Harbison <matt_harbison@yahoo.com>
# Date 1538191026 14400
#      Fri Sep 28 23:17:06 2018 -0400
# Node ID e3fa739c298dc8f34d10b882e324380c5d0638fa
# Parent  bf0bf1635b94a23f129abc44eacbde830e541544
py3: conditionalize json float precision difference in test-debugcommands.t

Patch

diff --git a/tests/test-debugcommands.t b/tests/test-debugcommands.t
--- a/tests/test-debugcommands.t
+++ b/tests/test-debugcommands.t
@@ -193,7 +193,8 @@  debugdelta chain basic output
    {
     "chainid": 1,
     "chainlen": 1,
-    "chainratio": 1.02325581395,
+    "chainratio": 1.02325581395, (no-py3k !)
+    "chainratio": 1.0232558139534884, (py3k !)
     "chainsize": 44,
     "compsize": 44,
     "deltatype": "base",
@@ -221,7 +222,8 @@  debugdelta chain basic output
    {
     "chainid": 3,
     "chainlen": 1,
-    "chainratio": 1.02325581395,
+    "chainratio": 1.02325581395, (no-py3k !)
+    "chainratio": 1.0232558139534884, (py3k !)
     "chainsize": 44,
     "compsize": 44,
     "deltatype": "base",
@@ -256,7 +258,8 @@  debugdelta chain with sparse read enable
    {
     "chainid": 1,
     "chainlen": 1,
-    "chainratio": 1.02325581395,
+    "chainratio": 1.02325581395, (no-py3k !)
+    "chainratio": 1.0232558139534884, (py3k !)
     "chainsize": 44,
     "compsize": 44,
     "deltatype": "base",
@@ -292,7 +295,8 @@  debugdelta chain with sparse read enable
    {
     "chainid": 3,
     "chainlen": 1,
-    "chainratio": 1.02325581395,
+    "chainratio": 1.02325581395, (no-py3k !)
+    "chainratio": 1.0232558139534884, (py3k !)
     "chainsize": 44,
     "compsize": 44,
     "deltatype": "base",