Skip to content
Snippets Groups Projects
Commit aced1dc1 authored by Brandon Hewer's avatar Brandon Hewer
Browse files

Fix all doctest errors

Refs #20820
parent 3b79a702
No related branches found
No related tags found
No related merge requests found
......@@ -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
......
......@@ -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:
......
......@@ -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:
......
......@@ -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)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment