Tests for define method