code: def test_date_time_exception(self):
      with self.assertRaises(DateTimeException):
          with self.sql_conf({"spark.sql.ansi.enabled": True}):
              self.spark.sql(
                  "select unix_timestamp('2023-01-01', 'dd-MM-yyyy')"
              ).show()
  
file_path: spark/python/pyspark/sql/tests/test_errors.py
imports: from pyspark.errors import ArithmeticException, ArrayIndexOutOfBoundsException, DateTimeException, NumberFormatException, SparkRuntimeException
  from pyspark.testing.sqlutils import ReusedSQLTestCase
label_desc: Use image node_id 3 for calling the ErrorsTestsMixin obj's underlying member method code with example usage: obj.test_date_time_exception() without return types