Closed asfimport closed 20 years ago
tjsb (migrated from Bugzilla): Created attachment SFF.patch: Various patches to StringFromFile
tjsb (migrated from Bugzilla): Created attachment crlast.patch: Updates to component_reference docs
The sumInt function can be used to compute the sum of two or more integer values.
+ The intsum function can be used to compute the sum of two or more integer values.
+ The StringFromFile function can be used to read strings from a text file.
+ This is useful for running tests that require lots of variable data.
+ For example when testing a banking application, 100s or 1000s of different account numbers might be required.
+
+ Each time it is called it reads the next line from the file.
+ When the end of the file is reached, it will start reading again from the beginning.
+ If there are multiple references to the function in a test script, each will open the file independently,
+ even if the file names are the same.
+ [If the value is to be used again elsewhere, use different variable names for each function call.]
+ If an error occurs opening or reading the file, then the function returns the string "**ERR**" The file name parameter is resolved when the file is opened or re-opened. The reference name parameter (if supplied) is resolved every time the function is executed.
Mike Stover (migrated from Bugzilla): patch applied - thank you!
tjsb (Bug 20152): The patch file (to follow) fixes the StringFromFile function:
Patch follows.
Severity: minor OS: other