Changeset

10977:29b9b679bdbc

util.dbuffer: Don't use # operator in tests, Lua 5.1 doesn't support __len
author Matthew Wild <mwild1@gmail.com>
date Sun, 28 Jun 2020 12:26:04 +0100
parents 10976:540f1bc5f082
children 10978:4d3247a1f6b3
files spec/util_dbuffer_spec.lua
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/spec/util_dbuffer_spec.lua	Sun Jun 28 12:02:10 2020 +0100
+++ b/spec/util_dbuffer_spec.lua	Sun Jun 28 12:26:04 2020 +0100
@@ -26,7 +26,7 @@
 		it("works", function ()
 			assert.truthy(b:write("hello world"));
 			assert.truthy(b:discard(6));
-			assert.equal(5, #b);
+			assert.equal(5, b:length());
 			assert.equal("world", b:read(5));
 		end);
 	end);