PowerDNS / pdns

PowerDNS Authoritative, PowerDNS Recursor, dnsdist
https://www.powerdns.com/
GNU General Public License v2.0
3.72k stars 913 forks source link

auth API: more consistent ordering #10102

Open Habbie opened 3 years ago

Habbie commented 3 years ago

https://github.com/PowerDNS/pdns/pull/10056 expands auth API testing to Postgres, MySQL and LMDB (besides the SQLite3 that was always tested). In this testing, some random failures popped up, apparently around the ordering of some results.

To counter that, five calls to self.assertEquals were replaced with self.assertCountEqual.

Ideally, API output would be consistent. I suspect a bit of sorting here and there would go a long way.

Once the API is improved like that, we should revert those five calls.

zeha commented 3 years ago

assertAlmostEqual might have been a better idea for the interim solution.