Fix a couple of INI whitespace bugs

* iniset() bails if no section or option (attribute) is supplied
* merge_config_file() properly skips lines with only whitespace

* Also split the ini-tests into their own script

Bug 1257954

Change-Id: Ie31c5bd0df8dfed129fbcf1e37228aaf25e9305d
diff --git a/functions b/functions
index 5ff4a9b..0280b2b 100644
--- a/functions
+++ b/functions
@@ -729,6 +729,8 @@
     local option=$3
     local value=$4
 
+    [[ -z $section || -z $option ]] && return
+
     if ! grep -q "^\[$section\]" "$file" 2>/dev/null; then
         # Add section at the end
         echo -e "\n[$section]" >>"$file"