shouldNotBe method

void shouldNotBe(
  1. T expected
)

Asserts that the value is not the same instance as expected, using identical.

Implementation

void shouldNotBe(T expected) => expect(this, isNot(same(expected)));