Changeset

7961:ff556d010225

tests: Trim trailing whitespace
author Kim Alvefur <zash@zash.se>
date Mon, 06 Mar 2017 16:01:27 +0100
parents 7960:9a938b785bc5
children 7962:4e9b307c30dd
files tests/test_utf8.lua tests/test_util_cache.lua tests/test_util_stanza.lua
diffstat 3 files changed, 20 insertions(+), 20 deletions(-) [+]
line wrap: on
line diff
--- a/tests/test_utf8.lua	Mon Mar 06 15:56:12 2017 +0100
+++ b/tests/test_utf8.lua	Mon Mar 06 16:01:27 2017 +0100
@@ -4,7 +4,7 @@
 function valid()
 	local encodings = require "util.encodings";
 	local utf8 = assert(encodings.utf8, "no encodings.utf8 module");
-	
+
 	for line in io.lines("utf8_sequences.txt") do
 		local data = line:match(":%s*([^#]+)"):gsub("%s+", ""):gsub("..", function (c) return string.char(tonumber(c, 16)); end)
 		local expect = line:match("(%S+):");
--- a/tests/test_util_cache.lua	Mon Mar 06 15:56:12 2017 +0100
+++ b/tests/test_util_cache.lua	Mon Mar 06 16:01:27 2017 +0100
@@ -10,7 +10,7 @@
 	expect_kv(nil, nil, c:tail());
 
 	assert_equal(c:count(), 0);
-	
+
 	c:set("one", 1)
 	assert_equal(c:count(), 1);
 	expect_kv("one", 1, c:head());
@@ -29,12 +29,12 @@
 	assert_equal(c:count(), 5);
 	expect_kv("five", 5, c:head());
 	expect_kv("one", 1, c:tail());
-	
+
 	c:set("foo", nil);
 	assert_equal(c:count(), 5);
 	expect_kv("five", 5, c:head());
 	expect_kv("one", 1, c:tail());
-	
+
 	assert_equal(c:get("one"), 1);
 	expect_kv("five", 5, c:head());
 	expect_kv("one", 1, c:tail());
@@ -46,32 +46,32 @@
 
 	assert_equal(c:get("foo"), nil);
 	assert_equal(c:get("bar"), nil);
-	
+
 	c:set("six", 6);
 	assert_equal(c:count(), 5);
 	expect_kv("six", 6, c:head());
 	expect_kv("two", 2, c:tail());
-	
+
 	assert_equal(c:get("one"), nil);
 	assert_equal(c:get("two"), 2);
 	assert_equal(c:get("three"), 3);
 	assert_equal(c:get("four"), 4);
 	assert_equal(c:get("five"), 5);
 	assert_equal(c:get("six"), 6);
-	
+
 	c:set("three", nil);
 	assert_equal(c:count(), 4);
-	
+
 	assert_equal(c:get("one"), nil);
 	assert_equal(c:get("two"), 2);
 	assert_equal(c:get("three"), nil);
 	assert_equal(c:get("four"), 4);
 	assert_equal(c:get("five"), 5);
 	assert_equal(c:get("six"), 6);
-	
+
 	c:set("seven", 7);
 	assert_equal(c:count(), 5);
-	
+
 	assert_equal(c:get("one"), nil);
 	assert_equal(c:get("two"), 2);
 	assert_equal(c:get("three"), nil);
@@ -79,10 +79,10 @@
 	assert_equal(c:get("five"), 5);
 	assert_equal(c:get("six"), 6);
 	assert_equal(c:get("seven"), 7);
-	
+
 	c:set("eight", 8);
 	assert_equal(c:count(), 5);
-	
+
 	assert_equal(c:get("one"), nil);
 	assert_equal(c:get("two"), nil);
 	assert_equal(c:get("three"), nil);
@@ -91,10 +91,10 @@
 	assert_equal(c:get("six"), 6);
 	assert_equal(c:get("seven"), 7);
 	assert_equal(c:get("eight"), 8);
-	
+
 	c:set("four", 4);
 	assert_equal(c:count(), 5);
-	
+
 	assert_equal(c:get("one"), nil);
 	assert_equal(c:get("two"), nil);
 	assert_equal(c:get("three"), nil);
@@ -103,10 +103,10 @@
 	assert_equal(c:get("six"), 6);
 	assert_equal(c:get("seven"), 7);
 	assert_equal(c:get("eight"), 8);
-	
+
 	c:set("nine", 9);
 	assert_equal(c:count(), 5);
-	
+
 	assert_equal(c:get("one"), nil);
 	assert_equal(c:get("two"), nil);
 	assert_equal(c:get("three"), nil);
@@ -268,7 +268,7 @@
 
 
 	local c4 = new(3, false);
-	
+
 	assert_equal(c4:set("a", 1), true);
 	assert_equal(c4:set("a", 1), true);
 	assert_equal(c4:set("a", 1), true);
@@ -290,7 +290,7 @@
 		end
 		return false;
 	end);
-	
+
 	assert_equal(c5:set("a", 1), true);
 	assert_equal(c5:set("a", 1), true);
 	assert_equal(c5:set("a", 1), true);
--- a/tests/test_util_stanza.lua	Mon Mar 06 15:56:12 2017 +0100
+++ b/tests/test_util_stanza.lua	Mon Mar 06 16:01:27 2017 +0100
@@ -37,7 +37,7 @@
 	assert_equal(s1.attr.xmlns, nil);
 	assert_equal(#s1, 0);
 	assert_equal(#s1.tags, 0);
-	
+
 	s1:tag("child1");
 	assert_equal(#s1.tags, 1);
 	assert_equal(s1.tags[1].name, "child1");
@@ -47,7 +47,7 @@
 	assert_equal(s1.tags[1].name, "child1");
 	assert_equal(#s1.tags[1], 1);
 	assert_equal(s1.tags[1][1].name, "grandchild1");
-	
+
 	s1:up():tag("child2");
 	assert_equal(#s1.tags, 2, tostring(s1));
 	assert_equal(s1.tags[1].name, "child1");