Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/stevedonovan/Penlight.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsteve donovan <steve.j.donovan@gmail.com>2012-03-26 14:28:18 +0400
committersteve donovan <steve.j.donovan@gmail.com>2012-03-26 14:28:18 +0400
commitb734be52ce3477883d4820328e99562b8e770da4 (patch)
tree92dd37023e6e7736fbb94da494746a3f865c5686
parenteb5a976dc40d08919bbcfbaa1fd4ffb7e80f1991 (diff)
makelist in array2d borked; tests depending on non-existent files1.0.1
-rw-r--r--lua/pl/array2d.lua2
-rw-r--r--tests/test-dir.lua4
-rw-r--r--tests/test-path.lua4
3 files changed, 5 insertions, 5 deletions
diff --git a/lua/pl/array2d.lua b/lua/pl/array2d.lua
index 14e2894..7fde031 100644
--- a/lua/pl/array2d.lua
+++ b/lua/pl/array2d.lua
@@ -28,7 +28,7 @@ local function obj (int,out)
end
local function makelist (res)
- setmetatable(res,utils.stdmt.List)
+ return setmetatable(res,utils.stdmt.List)
end
diff --git a/tests/test-dir.lua b/tests/test-dir.lua
index 5ed4935..c747604 100644
--- a/tests/test-dir.lua
+++ b/tests/test-dir.lua
@@ -8,9 +8,9 @@ local pretty = require( "pl.pretty" )
local normpath = path.normpath
-local expected = {normpath "../docs/function_index.txt"}
+local expected = {normpath "../docs/config.ld"}
-local files = dir.getallfiles( normpath "../docs/", "*.txt" )
+local files = dir.getallfiles( normpath "../docs/", "*.ld" )
asserteq( files, expected )
diff --git a/tests/test-path.lua b/tests/test-path.lua
index 6f06d3b..5a232df 100644
--- a/tests/test-path.lua
+++ b/tests/test-path.lua
@@ -21,10 +21,10 @@ testpath [[alice]]
testpath [[/path-to\dog\]]
asserteq( path.isdir( "../docs" ), true )
-asserteq( path.isdir( "../docs/penlight.jpg" ), false )
+asserteq( path.isdir( "../docs/config.ld" ), false )
asserteq( path.isfile( "../docs" ), false )
-asserteq( path.isfile( "../docs/penlight.jpg" ), true )
+asserteq( path.isfile( "../docs/config.ld" ), true )
local norm = path.normpath
local p = norm '/a/b'