On Fri, Jul 19, 2024 at 5:49 AM Tomas Vondra
<tomas.vondra@enterprisedb.com> wrote:
>
> Hi,
>
> If I understand correctly, the problem is that it's not clear which of
> the 'abc' substrings is matched/returned by the function, right?
>
> I wonder if this is a problem only for understanding the test, or if it
> makes the tests a bit weaker. I mean, what if the function returns the
> wrong substring? How would we know?
>
this is for understanding the test.
personally, sometimes, I feel the documentation is too dry, hard to follow.
so i can based on regress tests better understand the documentation.
that was my intention for the changes.
we have more sophisticated regex test at
https://git.postgresql.org/cgit/postgresql.git/tree/src/test/modules/test_regex
> Also, if we tweak this, shouldn't we tweak also the regext_instr() calls
> a bit earlier in the test script?
>
sure.
please check attached.