Sorry for late response but I am in Spain with only the telephone as an internet source so a bit restricted access.
Rick: from what you write it appears that in principle it is not possible to ::requires a class so that it works in both Win and *nix worlds? It would all have to be done outside of the program itself? The ::requires is checked when the program starts, hence it cannot be „filled in“ at runtime, right?To give the context:
I have started to write test cases for the ooRexx samples (another show stopper) and in doing so try to make them as portable as possible. I have copied the samples back from /<install directory>/share/ooRexx and grind through them to try to find meaningful tests and take note of things that may need amendment as I go along.
For the time being I keep the samples in a subdirectory /ooRexx of the test directory (hence the question), later I can change this with a search&replace.
I have attached the first 3 1/2 test cases, feel free to comment on what you (or any developer) consider needs to be changed/added/improved/deleted.
A question in the same context: how do I redirect standard input to a rexx program from a test case in the best way? I need to feed some samples with input that is supposed to come from the user. I have never done this so any help is welcome. |
Samples.testGroup
Description: Binary data
Von meinen Macbook gesendet
Hälsningar/Regards/Grüsse, P.O. Jonsson
No, the ::requires has to be a constant literal string or symbol.
Rick Is it possible to build the string using the separator method of the File
class, store it in a string, and refer to it in the ::requires statement?
e.g.
reqPath = 'ooRexx'.file~separator'complex.rex'
Leslie
On 2018-10-14 15:34:18 Rick McGuire wrote:
> Really not good practice to do this. A better choice would be to add the
> subdirectory to your path and just use the simple name.
>
> Rick
>
> On Sun, Oct 14, 2018 at 3:52 PM P.O. Jonsson <oor...@jonases.se> wrote:
> > Dear ooRexxers,
> >
> > I need to require a file from a subdirectory, like this
> >
> > ::requires 'ooRexx/complex.rex' -- load the complex class
> >
> > My question is: how can I make this so that it works on both Mac and Win?
> >
> > The Win version of this would be (I guess, no Win machine at hand):
> > ::requires 'ooRexx\complex.rex' -- load the complex class
> >
> > I need something that works on all ooRexx platforms (Win, Darwin, Linux,
> > AIX, ARM-32 and any other)
> >
> > Von meinen Macbook gesendet
> >
> > Hälsningar/Regards/Grüsse,
> > P.O. Jonsson
> > oor...@jonases.se
> >
> >
> >
> > _______________________________________________
> > Oorexx-users mailing list
> > Oorexx-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/oorexx-users
_______________________________________________
Oorexx-users mailing list
Oorexx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-users
_______________________________________________ Oorexx-users mailing list Oorexx-users@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/oorexx-users
|
_______________________________________________
Oorexx-users mailing list
Oorexx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-users