On Mon, 18 Apr 2016, Luiz Americo Pereira Camara wrote:

2016-04-18 13:47 GMT-03:00 Bart <bartjun...@gmail.com>:

[..]

The internal processing of the (edit)mask is the same as TMaskEdit.
If that is broken somehow, it is also broken in TMaskEdit.

The only functions that may need adjustments are

* function FormatMaskText(const EditMask: string; const AValue: string):
string;
* function FormatMaskInput(const EditMask: string): string;
* function MaskDoFormatText(const EditMask: string; const AValue: string;
                   ASpaceChar: Char): string;
* function TMaskUtils.TryValidateInput(out ValidatedString: String):
Boolean;

But since there is no real documentation and there is no test suite,
it's hard to tell if they do not function as they should or introduce
regressions.


I propose to write a test suite first with the desired output, based on
Delphi.

I agree 100%


Given that the implementation becomes a detail, subject to changes in
future.

I can take the duty of starting, just need to know the format. fpcunit or
plain tests like most fpc tests?

fpcunit. 'most fpc tests' are for the compiler, not for unit functionality.

Michael.
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Reply via email to