8000 fixed automated test to match new tweaks of pymas · teoland/python-sasctl@7f53126 · GitHub
[go: up one dir, main page]

Skip to content

Commit 7f53126

Browse files
author
Cloud User
committed
fixed automated test to match new tweaks of pymas
1 parent 595a516 commit 7f53126

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

tests/integration/test_pymas.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,12 @@ def test_from_pickle(train_data, pickle_file):
184184
rc = py.appendSrcLine(' raise _compile_error');
185185
rc = py.appendSrcLine(' msg = ""');
186186
rc = py.appendSrcLine(' import numpy as np');
187-
rc = py.appendSrcLine(' result = obj.predict(np.array([SepalLength,SepalWidth,PetalLength,PetalWidth]).reshape((1, -1)))');
187+
rc = py.appendSrcLine('');
188+
rc = py.appendSrcLine(' inputarray = np.array([SepalLength,SepalWidth,PetalLength,PetalWidth]).reshape((1, -1))');
189+
rc = py.appendSrcLine(' column=["CRIM","ZN","INDUS","CHAS","NOX","RM","AGE","DIS","RAD","TAX","PTRATIO","B","LSTAT"]');
190+
rc = py.appendSrcLine(' import pandas as pd');
191+
rc = py.appendSrcLine(' inputrun=pd.DataFrame(data=inputarray, columns=column)');
192+
rc = py.appendSrcLine(' result = obj.predict(inputrun)');
188193
rc = py.appendSrcLine(' if result.size == 1:');
189194
rc = py.appendSrcLine(' result = np.asscalar(result)');
190195
rc = py.appendSrcLine(' except Exception as e:');

0 commit comments

Comments
 (0)
0