Updated patch is attached. All tests are passing. Please see the attachment and let me know if any further changes are to be made.


On 25 February 2014 21:25, Jakub Hrozek <jhrozek@redhat.com> wrote:
On Mon, Feb 17, 2014 at 04:47:09PM +0100, Lukas Slebodnik wrote:
> The test(s) don't pass because they cannot pass.
> You used function create_dom_test_ctx and param with filter_groups and
> filter_users and result of this is configuration:
> [domain/nss_test]
> filter_users = testuser1
> filter_groups = testgroup1
> But negative cache reads configuration options from [nss] section.

No, it reads from both actually and domain takes precedence.

> [nss]
> filter_users = testuser1
> filter_groups = testgroup1

There was two different bugs in the test. Because the domain structure
was created with talloc, the ->next pointer was random data and a for
loop that walked through the list of domains crashed.

The second bug was that the test used different domain name for the
domain structure (NAME) and a different name when generating the
configuration (TEST_DOM_NAME) so the config was never read actually.

Attached is a snippet that I used to fix the test. Pallavi, if you
agree, please resubmit your patch with the snippet squashed in.

btw I didn't know what was test_sss_ncache_reset_permanent() about, so I
removed it during my testing..feel free to retain it in the final patch,
but please don't leave if-ed code in the resulting test.