You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Thank you for your help in testing! Updated MTTester.mqh posted.
Thank you very much for the library
This Expert Advisor presses the Start button every three seconds, if it is not Stop. I managed to press it - true, otherwise - false.
Standard situation.
Pressed Start - the calculation started.
This action takes ~125 ms.
It's not uncommon.
Press Start - either instantaneous calculation is started, or the Tester reports that it cannot perform the calculation (e.g. FromDate >= ToDate).
This action takes about a second. The library will alerter, but will return true - the button was pressed.
Rare situation.
Start is not pressed. This can be cured only by rebooting the Terminal.
I don't have logs of this situation. It will take <10 seconds to identify such a situation. There will be an alert like this.
Return false - the button was not pressed.
A rare situation.
Start is not pressed. This can be cured only by rebooting the Terminal.
A remote WinServer machine was continuously making hundreds of single passes without any failures.
As soon as I logged in (RDP) to this machine, the Start button stopped clicking. The cure, as always, is to reboot the Terminal.
It seems that this behaviour has something to do with similar logins to the machine. You can log in via RDP dozens of times - everything works fine. But some login becomes fatal for the Tester.
Those who encounter the Start-bug - pay attention to the relationship between logging in to the machine and the Start button.
ZY Coincidence or not, WinServer offered to check its updates during this logon to the machine.
Good library.
Is it possible to specify which *.set file with parameter settings to pass programmatically for the test?
By default only the same settings are used, which is not very convenient.
Is it possible to specify which *.set file with parameter settings to pass programmatically for the test?
Example.
Thank you.
Is it better to pass Settings in a single line with rows separated by \n character.
or an array of rows as in the example?
And is it possible to modify in
MTTester class static method Run
static bool Run( const string ExpertName = NULL,
const string Symb = NULL,
const ENUM_TIMEFRAMES period = PERIOD_CURRENT,
const datetime iBeginTime = 0,
const datetime iEndTime = 0 )
add one parameter string ( or an array of strings ) that specify *.set EA settings?
Thank you.
Is it better to pass Settings in a single line with rows separated by \n character?
or an array of rows like in the example?
GetSettings is CTRL+C in Tester.
SetSettings is CTRL+V in Tester.
See what data CTRL+C/V works with.
And whether it is possible to modify in
MTTester class static method Run
I don't use this method. It remains as history.
The example shows all MTTESTER methods that are needed.
Is it possible to specify which *.set file with parameter settings to pass programmatically for the test?
Validate works with full-fledged ini files of the Tester and a reduced version - set-files for the Tester.
If you need to run a lot of ini/set files, Validate does it out of the box. Use.
Validate works with full-fledged Tester ini-files and a stripped-down version - set-files for Tester.
If you need to run a lot of ini/set-files, Validate does it out of the box. Use.
Thank you.
I found a solution from this comment where the set file is loaded in the required format as a string array.
https://www.mql5.com/ru/forum/318305/page34#comment_51842356
I also replaced
typedef bool (*INITDEINIT)( void );
pointer of callback calls at initialisation and deinitialisation of each run
to the interface
interface InitDeInit {
bool RunInit();
bool RunDeInit();
};
which is implemented in the inheritor
of a class similar to the structure SETTINGS
and so in the RunInit() method.
I load the set file of the required tool.
typedef bool (*INITDEINIT)( void ); - such a pointer does not allow you to know which tool is initialising/deinitialising, so it is better to use a pointer to the interface because pointers to methods are not supported by MQL yet.
With this approach there is no need to modify MTTester::Run method.