From aced1dc103e35b723420df6e468c20d514fc134d Mon Sep 17 00:00:00 2001
From: Brandon Hewer <brandon.hewer@stfc.ac.uk>
Date: Thu, 5 Oct 2017 16:58:48 +0100
Subject: [PATCH] Fix all doctest errors

Refs #20820
---
 docs/source/algorithms/RetrieveRunInfo-v1.rst         | 6 +++---
 docs/source/algorithms/RunPythonScript-v1.rst         | 2 +-
 docs/source/algorithms/SANSWideAngleCorrection-v1.rst | 2 +-
 docs/source/algorithms/SassenaFFT-v1.rst              | 2 +-
 4 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/docs/source/algorithms/RetrieveRunInfo-v1.rst b/docs/source/algorithms/RetrieveRunInfo-v1.rst
index 630306b2930..74efd6c926c 100644
--- a/docs/source/algorithms/RetrieveRunInfo-v1.rst
+++ b/docs/source/algorithms/RetrieveRunInfo-v1.rst
@@ -55,9 +55,9 @@ Usage
    info_table = RetrieveRunInfo(Runs="IRS21360,IRS26173")
 
    print("The table contains information about {} runs.".format(info_table.rowCount()))
-   print "The first has run number {}.".format(info_table.cell("run_number", 0)))
-   print "The second has run number {}.".format(info_table.cell("run_number", 1)))
-   print "The title of the second run is \"{}.\"".format(info_table.cell("run_title", 1).strip()))
+   print("The first has run number {}.".format(info_table.cell("run_number", 0)))
+   print("The second has run number {}.".format(info_table.cell("run_number", 1)))
+   print("The title of the second run is \"{}.\"".format(info_table.cell("run_title", 1).strip()))
 
 .. testcleanup:: ExSingleRun
 
diff --git a/docs/source/algorithms/RunPythonScript-v1.rst b/docs/source/algorithms/RunPythonScript-v1.rst
index c667a6cab2f..ea1888422f5 100644
--- a/docs/source/algorithms/RunPythonScript-v1.rst
+++ b/docs/source/algorithms/RunPythonScript-v1.rst
@@ -41,7 +41,7 @@ Usage
     RunPythonScript(InputWorkspace=ws,Code=script,OutputWorkspace="wsOut")
 
     wsOut = mtd["wsOut"]
-    print("The workspace contained a total of {} counts".format(wsOut.readY(0)[0]))
+    print("The workspace contained a total of {:d} counts".format(wsOut.readY(0)[0]))
 
 Output:
 
diff --git a/docs/source/algorithms/SANSWideAngleCorrection-v1.rst b/docs/source/algorithms/SANSWideAngleCorrection-v1.rst
index 95090f62b91..e40584ed0b2 100644
--- a/docs/source/algorithms/SANSWideAngleCorrection-v1.rst
+++ b/docs/source/algorithms/SANSWideAngleCorrection-v1.rst
@@ -149,7 +149,7 @@ Usage
 
    corrected_data = SANSWideAngleCorrection(sample, transmission)
 
-   print("{} was corrected to {}.".format(sample.readY(19)[0], corrected_data.readY(19)[0]))
+   print("{:.6} was corrected to {:.6}.".format(sample.readY(19)[0], corrected_data.readY(19)[0]))
 
 Output:
 
diff --git a/docs/source/algorithms/SassenaFFT-v1.rst b/docs/source/algorithms/SassenaFFT-v1.rst
index b3403d79625..eb383732e69 100644
--- a/docs/source/algorithms/SassenaFFT-v1.rst
+++ b/docs/source/algorithms/SassenaFFT-v1.rst
@@ -70,7 +70,7 @@ Usage
     ws = LoadSassena("loadSassenaExample.h5", TimeUnit=1.0)
     SassenaFFT(ws, FFTonlyRealPart=1, Temp=1000, DetailedBalance=1)
 
-    print('workspaces instantiated:  {}.format(', '.join(ws.getNames())))
+    print('workspaces instantiated:  {}.format(', '.join(ws.getNames()))
 
     sqt = ws[3] # S(Q,E)
     # I(Q,t) is a Gaussian, thus S(Q,E) is a Gaussian too (at high temperatures)
-- 
GitLab