mirror of
https://github.com/yabwon/SAS_PACKAGES.git
synced 2026-01-07 15:10:04 +00:00
version 20200827
version 20200827, -improvement in the testing part of the framework code
This commit is contained in:
@@ -42,7 +42,7 @@
|
|||||||
- to unload, or
|
- to unload, or
|
||||||
- to generate SAS packages.
|
- to generate SAS packages.
|
||||||
|
|
||||||
Version 20200811.
|
Version 20200827.
|
||||||
See examples below.
|
See examples below.
|
||||||
|
|
||||||
A SAS package is a zip file containing a group of files
|
A SAS package is a zip file containing a group of files
|
||||||
@@ -81,7 +81,7 @@
|
|||||||
*/
|
*/
|
||||||
)/secure
|
)/secure
|
||||||
/*** HELP END ***/
|
/*** HELP END ***/
|
||||||
des = 'Macro to load SAS package, version 20200811. Run %loadPackage() for help info.'
|
des = 'Macro to load SAS package, version 20200827. Run %loadPackage() for help info.'
|
||||||
;
|
;
|
||||||
%if (%superq(packageName) = ) OR (%qupcase(&packageName.) = HELP) %then
|
%if (%superq(packageName) = ) OR (%qupcase(&packageName.) = HELP) %then
|
||||||
%do;
|
%do;
|
||||||
@@ -96,7 +96,7 @@ des = 'Macro to load SAS package, version 20200811. Run %loadPackage() for help
|
|||||||
%put # This is short help information for the loadPackage macro #;
|
%put # This is short help information for the loadPackage macro #;
|
||||||
%put ###############################################################################;
|
%put ###############################################################################;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # Macro to load SAS packages, version 20200811 #;
|
%put # Macro to load SAS packages, version 20200827 #;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # A SAS package is a zip file containing a group #;
|
%put # A SAS package is a zip file containing a group #;
|
||||||
%put # of SAS codes (macros, functions, data steps generating #;
|
%put # of SAS codes (macros, functions, data steps generating #;
|
||||||
@@ -242,7 +242,7 @@ des = 'Macro to load SAS package, version 20200811. Run %loadPackage() for help
|
|||||||
*/
|
*/
|
||||||
)/secure
|
)/secure
|
||||||
/*** HELP END ***/
|
/*** HELP END ***/
|
||||||
des = 'Macro to unload SAS package, version 20200811. Run %unloadPackage() for help info.'
|
des = 'Macro to unload SAS package, version 20200827. Run %unloadPackage() for help info.'
|
||||||
;
|
;
|
||||||
%if (%superq(packageName) = ) OR (%qupcase(&packageName.) = HELP) %then
|
%if (%superq(packageName) = ) OR (%qupcase(&packageName.) = HELP) %then
|
||||||
%do;
|
%do;
|
||||||
@@ -257,7 +257,7 @@ des = 'Macro to unload SAS package, version 20200811. Run %unloadPackage() for h
|
|||||||
%put # This is short help information for the unloadPackage macro #;
|
%put # This is short help information for the unloadPackage macro #;
|
||||||
%put ###############################################################################;
|
%put ###############################################################################;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # Macro to unload SAS packages, version 20200811 #;
|
%put # Macro to unload SAS packages, version 20200827 #;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # A SAS package is a zip file containing a group #;
|
%put # A SAS package is a zip file containing a group #;
|
||||||
%put # of SAS codes (macros, functions, data steps generating #;
|
%put # of SAS codes (macros, functions, data steps generating #;
|
||||||
@@ -376,7 +376,7 @@ des = 'Macro to unload SAS package, version 20200811. Run %unloadPackage() for h
|
|||||||
*/
|
*/
|
||||||
)/secure
|
)/secure
|
||||||
/*** HELP END ***/
|
/*** HELP END ***/
|
||||||
des = 'Macro to get help about SAS package, version 20200811. Run %helpPackage() for help info.'
|
des = 'Macro to get help about SAS package, version 20200827. Run %helpPackage() for help info.'
|
||||||
;
|
;
|
||||||
%if (%superq(packageName) = ) OR (%qupcase(&packageName.) = HELP) %then
|
%if (%superq(packageName) = ) OR (%qupcase(&packageName.) = HELP) %then
|
||||||
%do;
|
%do;
|
||||||
@@ -391,7 +391,7 @@ des = 'Macro to get help about SAS package, version 20200811. Run %helpPackage()
|
|||||||
%put # This is short help information for the helpPackage macro #;
|
%put # This is short help information for the helpPackage macro #;
|
||||||
%put ###############################################################################;
|
%put ###############################################################################;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # Macro to get help about SAS packages, version 20200811 #;
|
%put # Macro to get help about SAS packages, version 20200827 #;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # A SAS package is a zip file containing a group #;
|
%put # A SAS package is a zip file containing a group #;
|
||||||
%put # of SAS codes (macros, functions, data steps generating #;
|
%put # of SAS codes (macros, functions, data steps generating #;
|
||||||
@@ -496,7 +496,7 @@ TODO:
|
|||||||
- add MD5(&packageName.) value hash instead "package" word in filenames [DONE]
|
- add MD5(&packageName.) value hash instead "package" word in filenames [DONE]
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Macros to install SAS packages, version 20200811 */
|
/* Macros to install SAS packages, version 20200827 */
|
||||||
/* A SAS package is a zip file containing a group of files
|
/* A SAS package is a zip file containing a group of files
|
||||||
with SAS code (macros, functions, data steps generating
|
with SAS code (macros, functions, data steps generating
|
||||||
data, etc.) wrapped up together and %INCLUDEed by
|
data, etc.) wrapped up together and %INCLUDEed by
|
||||||
@@ -511,7 +511,7 @@ TODO:
|
|||||||
)
|
)
|
||||||
/secure
|
/secure
|
||||||
/*** HELP END ***/
|
/*** HELP END ***/
|
||||||
des = 'Macro to install SAS package, version 20200811. Run %%installPackage() for help info.'
|
des = 'Macro to install SAS package, version 20200827. Run %%installPackage() for help info.'
|
||||||
;
|
;
|
||||||
%if (%superq(packageName) = ) OR (%qupcase(&packageName.) = HELP) %then
|
%if (%superq(packageName) = ) OR (%qupcase(&packageName.) = HELP) %then
|
||||||
%do;
|
%do;
|
||||||
@@ -526,7 +526,7 @@ des = 'Macro to install SAS package, version 20200811. Run %%installPackage() fo
|
|||||||
%put # This is short help information for the installPackage macro #;
|
%put # This is short help information for the installPackage macro #;
|
||||||
%put ########################################################################################;
|
%put ########################################################################################;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # Macro to install SAS packages, version 20200811 #;
|
%put # Macro to install SAS packages, version 20200827 #;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # A SAS package is a zip file containing a group #;
|
%put # A SAS package is a zip file containing a group #;
|
||||||
%put # of SAS codes (macros, functions, data steps generating #;
|
%put # of SAS codes (macros, functions, data steps generating #;
|
||||||
@@ -790,7 +790,7 @@ des = 'Macro to install SAS package, version 20200811. Run %%installPackage() fo
|
|||||||
|
|
||||||
/* Macro to list SAS packages in packages folder.
|
/* Macro to list SAS packages in packages folder.
|
||||||
|
|
||||||
Version 20200811
|
Version 20200827
|
||||||
|
|
||||||
A SAS package is a zip file containing a group
|
A SAS package is a zip file containing a group
|
||||||
of SAS codes (macros, functions, data steps generating
|
of SAS codes (macros, functions, data steps generating
|
||||||
@@ -810,7 +810,7 @@ des = 'Macro to install SAS package, version 20200811. Run %%installPackage() fo
|
|||||||
|
|
||||||
|
|
||||||
%macro listPackages()/PARMBUFF
|
%macro listPackages()/PARMBUFF
|
||||||
des = 'Macro to list SAS packages from `packages` fileref, type %listPackages(HELP) for help, version 20200811.'
|
des = 'Macro to list SAS packages from `packages` fileref, type %listPackages(HELP) for help, version 20200827.'
|
||||||
;
|
;
|
||||||
%if %QUPCASE(&SYSPBUFF.) = %str(%(HELP%)) %then
|
%if %QUPCASE(&SYSPBUFF.) = %str(%(HELP%)) %then
|
||||||
%do;
|
%do;
|
||||||
@@ -825,7 +825,7 @@ des = 'Macro to list SAS packages from `packages` fileref, type %listPackages(HE
|
|||||||
%put # This is short help information for the listPackages macro #;
|
%put # This is short help information for the listPackages macro #;
|
||||||
%put ########################################################################################;
|
%put ########################################################################################;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # Macro to list available SAS packages, version 20200811 #;
|
%put # Macro to list available SAS packages, version 20200827 #;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # A SAS package is a zip file containing a group #;
|
%put # A SAS package is a zip file containing a group #;
|
||||||
%put # of SAS codes (macros, functions, data steps generating #;
|
%put # of SAS codes (macros, functions, data steps generating #;
|
||||||
@@ -947,7 +947,7 @@ options ls = &ls_tmp. ps = &ps_tmp. ¬es_tmp. &source_tmp.;
|
|||||||
|
|
||||||
/* Macro to generate SAS packages.
|
/* Macro to generate SAS packages.
|
||||||
|
|
||||||
Version 20200811
|
Version 20200827
|
||||||
|
|
||||||
A SAS package is a zip file containing a group
|
A SAS package is a zip file containing a group
|
||||||
of SAS codes (macros, functions, data steps generating
|
of SAS codes (macros, functions, data steps generating
|
||||||
@@ -970,7 +970,7 @@ options ls = &ls_tmp. ps = &ps_tmp. ¬es_tmp. &source_tmp.;
|
|||||||
dependencies in loading */
|
dependencies in loading */
|
||||||
)/secure
|
)/secure
|
||||||
/*** HELP END ***/
|
/*** HELP END ***/
|
||||||
des = 'Macro to generate SAS packages, version 20200811. Run %generatePackage() for help info.'
|
des = 'Macro to generate SAS packages, version 20200827. Run %generatePackage() for help info.'
|
||||||
;
|
;
|
||||||
%if (%superq(filesLocation) = ) OR (%qupcase(&filesLocation.) = HELP) %then
|
%if (%superq(filesLocation) = ) OR (%qupcase(&filesLocation.) = HELP) %then
|
||||||
%do;
|
%do;
|
||||||
@@ -985,7 +985,7 @@ des = 'Macro to generate SAS packages, version 20200811. Run %generatePackage()
|
|||||||
%put # This is short help information for the generatePackage macro #;
|
%put # This is short help information for the generatePackage macro #;
|
||||||
%put ###############################################################################;
|
%put ###############################################################################;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # Macro to generate SAS packages, version 20200811 #;
|
%put # Macro to generate SAS packages, version 20200827 #;
|
||||||
%put # #;
|
%put # #;
|
||||||
%put # A SAS package is a zip file containing a group #;
|
%put # A SAS package is a zip file containing a group #;
|
||||||
%put # of SAS codes (macros, functions, data steps generating #;
|
%put # of SAS codes (macros, functions, data steps generating #;
|
||||||
@@ -2187,7 +2187,7 @@ data _null_;
|
|||||||
put ' end ; ';
|
put ' end ; ';
|
||||||
%end;
|
%end;
|
||||||
|
|
||||||
put 'put "***"; put "* SAS package generated by generatePackage, version 20200811 *"; put "***";';
|
put 'put "***"; put "* SAS package generated by generatePackage, version 20200827 *"; put "***";';
|
||||||
|
|
||||||
put 'run; ' /;
|
put 'run; ' /;
|
||||||
|
|
||||||
@@ -2412,6 +2412,16 @@ data _null_;
|
|||||||
put " path=&filesLocation.) " /;
|
put " path=&filesLocation.) " /;
|
||||||
run;
|
run;
|
||||||
|
|
||||||
|
/*
|
||||||
|
setup for testing session:
|
||||||
|
-sysin - file with the test code
|
||||||
|
-print - location of the *.lst output file
|
||||||
|
-log - location of the log file
|
||||||
|
-config - location of the default config file, i.e. "&SASROOT./sasv9.cfg"
|
||||||
|
-work - location for work
|
||||||
|
-noterminal - for batch execution mode
|
||||||
|
-rsasuser - to avoid the "Unable to copy SASUSER registry to WORK registry." warning
|
||||||
|
*/
|
||||||
systask kill sas0 wait;
|
systask kill sas0 wait;
|
||||||
%local sasstat0 TEST_0 TESTRC_0;;
|
%local sasstat0 TEST_0 TESTRC_0;;
|
||||||
%let TEST_0 = loading;
|
%let TEST_0 = loading;
|
||||||
@@ -2422,7 +2432,8 @@ systask command
|
|||||||
-log ""&dirForTest./&TEST_0..log""
|
-log ""&dirForTest./&TEST_0..log""
|
||||||
-config ""&SASROOT./sasv9.cfg""
|
-config ""&SASROOT./sasv9.cfg""
|
||||||
-work ""&dirForTest./work""
|
-work ""&dirForTest./work""
|
||||||
-noterminal"
|
-noterminal
|
||||||
|
-rsasuser"
|
||||||
taskname=sas0
|
taskname=sas0
|
||||||
status=sasstat0
|
status=sasstat0
|
||||||
WAIT
|
WAIT
|
||||||
@@ -2432,7 +2443,6 @@ WAIT
|
|||||||
data _null_;
|
data _null_;
|
||||||
infile "./loading.log" dlm='0a0d'x end=EOF;
|
infile "./loading.log" dlm='0a0d'x end=EOF;
|
||||||
input;
|
input;
|
||||||
if _N_ > 10; /* due to "Unable to copy SASUSER registry to WORK registry." */
|
|
||||||
if _INFILE_ =: 'WARNING:' then
|
if _INFILE_ =: 'WARNING:' then
|
||||||
do;
|
do;
|
||||||
warning+1;
|
warning+1;
|
||||||
@@ -2504,7 +2514,8 @@ systask command
|
|||||||
-config ""&SASROOT./sasv9.cfg""
|
-config ""&SASROOT./sasv9.cfg""
|
||||||
-work ""&dirForTest./work""
|
-work ""&dirForTest./work""
|
||||||
-autoexec ""&dirForTest./autoexec.sas""
|
-autoexec ""&dirForTest./autoexec.sas""
|
||||||
-noterminal"
|
-noterminal
|
||||||
|
-rsasuser"
|
||||||
taskname=sas&t.
|
taskname=sas&t.
|
||||||
status=sasstat&t.
|
status=sasstat&t.
|
||||||
WAIT
|
WAIT
|
||||||
@@ -2514,7 +2525,6 @@ WAIT
|
|||||||
data _null_;
|
data _null_;
|
||||||
infile "./&&TEST_&t...log" dlm='0a0d'x end=EOF;
|
infile "./&&TEST_&t...log" dlm='0a0d'x end=EOF;
|
||||||
input;
|
input;
|
||||||
if _N_ > 10; /* due to "Unable to copy SASUSER registry to WORK registry." */
|
|
||||||
if _INFILE_ =: 'WARNING:' then
|
if _INFILE_ =: 'WARNING:' then
|
||||||
do;
|
do;
|
||||||
warning+1;
|
warning+1;
|
||||||
|
|||||||
Reference in New Issue
Block a user