1
0
mirror of https://github.com/sasjs/core.git synced 2026-01-03 15:40:05 +00:00

fix: avoid open file handle when the variable to find is not provided (in mf_existvar)

Includes a test that was failing and is now passing
This commit is contained in:
allan
2023-04-05 15:29:53 +01:00
parent 7471bd42a4
commit 32dd057e83
3 changed files with 36 additions and 8 deletions

View File

@@ -17,4 +17,24 @@
%mp_assert(
iftrue=(%mf_existvar(sashelp.class,isjustanumber)=0),
desc=Checking non existing var does not exist
)
data work.lockcheck;
a=1;
output;
stop;
run;
%mp_assert(
iftrue=(%mf_existvar(work.lockcheck,)=0),
desc=Checking non-provided var does not exist
)
proc sql;
update work.lockcheck set a=2;
%mp_assert(
iftrue=(&syscc=0),
desc=Checking the lock was released,
outds=work.test_results
)