Skip to content

Arrayref with arrays is the same as arrayref with scalars #2

@bessarabov

Description

@bessarabov

Here is my problem. I'm not sure if this is a bug in Test::Differences or this is the expected behaviour (actually I'm not expecting Test::Differences to work in this way).

#!/usr/bin/perl

use strict;
use warnings FATAL => 'all';

use Test::More;
use Test::Differences;

# This tests fails as expected
is_deeply(
    [[1]],
    [1],
    'The arrayref with arrays is not the same as arrayref'
);

# I exect this test fail, but with Test::Differences 0.61 it passes
eq_or_diff_data(
    [[1]],
    [1],
    'The arrayref with arrays is not the same as arrayref'
);

done_testing();

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions