From fc932a9a8f40cb696a6af6a098a79209a6e7aa8d Mon Sep 17 00:00:00 2001 From: Kamil Tekiela Date: Mon, 15 Aug 2022 14:19:17 +0100 Subject: Allow fields to be set to NULL Signed-off-by: Kamil Tekiela --- test/classes/InsertEditTest.php | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'test') diff --git a/test/classes/InsertEditTest.php b/test/classes/InsertEditTest.php index 13ee204b74..590fa810d3 100644 --- a/test/classes/InsertEditTest.php +++ b/test/classes/InsertEditTest.php @@ -2143,6 +2143,30 @@ class InsertEditTest extends AbstractTestCase ], $result ); + + // Test to see if a field can be set to NULL + $result = $this->insertEdit->getQueryValuesForInsertAndUpdateInMultipleEdit( + $multi_edit_columns_name, + ['on'], + '', + [''], + [], + false, + [], + [], + 'NULL', + [], + '0', + [] + ); + + $this->assertEquals( + [ + ['`fld` = NULL'], + [], + ], + $result + ); } /** -- cgit v1.2.3