def test_variable_without_shape_from_callable_initializer(self):
        """Test that Variable raises error
        if shape is not provided for callable initializer."""
        with self.assertRaisesRegex(
            ValueError, "When creating a Variable from an initializer"
        ):
            backend.Variable(initializer=lambda: np.ones((2, 2)))
Test that Variable raises error
        if shape is not provided for callable initializer.
keras/src/backend/common/variables_test.py