Re: [PATCH 2/2] overlay/013: do not expect failure

Amir Goldstein
2018-04-16T15:27:51Z

On Mon, Apr 16, 2018 at 1:41 PM, Miklos Szeredi <mszeredi@redhat.com> wrote:
> Current test expects test_lower to fail with:
>
> truncate(test_lower) should have failed
>
> While it is sort of okay to fail like that (the above expectation basically
> acknowledges this weirdness in the overlayfs implementation), it is by no
> means the only correct behavior: it is also correct for the test to
> succeed (i.e. truncation fails with ETXTBSY).
>
> So add an option to t_truncate_self.c that allows both success and failure,
> but obviously not SIGSEGV, which is what a we'd get in a real failure mode.
>
> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>

Looks good.

Thanks,
Amir.