From: | Aleksander Alekseev <aleksander(at)timescale(dot)com> |
---|---|
To: | PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Cc: | Stepan Neretin <sndcppg(at)gmail(dot)com> |
Subject: | Re: [PATCH] Improve code coverage of network address functions |
Date: | 2024-10-31 18:19:57 |
Message-ID: | CAJ7c6TOi3c4nRhsuPNtr0GeJ34+si9EJH_eYOGfzRk3cHGQiLw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi Stepan,
> Hello Aleksander! I'm a beginner and I would like to see and try your patch. However, I have never worked with coverage in regression tests for PostgreSQL. Could you please tell me how it works and help me understand the process? Thanks!
You are going to need some Linux distribution, GCC stack and lcov 1.16
[1]. (Lcov doesn't work with Clang; We seem to experience some
problems with lcov 2.0+, this is being investigated [2])
Apply the patch as usual ( git clone
git://git.postgresql.org/git/postgresql.git ; git am ... ) and run:
```
git clean -dfx && meson setup --buildtype debug
-DPG_TEST_EXTRA="kerberos ldap ssl" -Db_coverage=true -Dldap=disabled
-Dssl=openssl -Dcassert=true -Dtap_tests=enabled
-Dprefix=/home/eax/pginstall build && ninja -C build &&
PG_TEST_EXTRA=1 meson test -C build && ninja -C build coverage-html
```
Note the `-Db_coverage=true` and `ninja -C build coverage-html` parts.
Change `prefix` to an appropriate one. This will take longer than
usual. Your coverage report will be located in
build/meson-logs/coveragereport. You can compare the reports with and
without the patch to ensure that the patch improves code coverage.
[1]: https://github.com/linux-test-project/lcov/releases/tag/v1.16
[2]: https://postgr.es/m/CAJ7c6TN%2BMCh99EZ8YGhXZAdnqvNQYir6E34B_mmcB5KsxCB00A%40mail.gmail.com
--
Best regards,
Aleksander Alekseev
From | Date | Subject | |
---|---|---|---|
Next Message | Andrey M. Borodin | 2024-10-31 18:45:49 | Re: UUID v7 |
Previous Message | Andrey M. Borodin | 2024-10-31 18:18:21 | Re: Using read stream in autoprewarm |