From ba360f5defe0090607963da1dd6104f11f0b595f Mon Sep 17 00:00:00 2001 From: s-ol Date: Fri, 4 Dec 2020 17:07:07 +0100 Subject: remove relative import system --- spec/stores_spec.moon | 2 -- spec/test_util.moon | 18 ------------------ 2 files changed, 20 deletions(-) (limited to 'spec') diff --git a/spec/stores_spec.moon b/spec/stores_spec.moon index 7fa2793..4ba838e 100644 --- a/spec/stores_spec.moon +++ b/spec/stores_spec.moon @@ -90,8 +90,6 @@ test_store = (ts) -> assert.are.same root_index, ts\get_index '', -1 - it "can get indexes recursively", -> - it "can load facets", -> assert.are.equal 'hello', ts\load_facet '/hello', 'name', 'alpha' assert.are.equal 'world', ts\load_facet '/hello/world', 'name', 'alpha' diff --git a/spec/test_util.moon b/spec/test_util.moon index b2ac026..e816286 100644 --- a/spec/test_util.moon +++ b/spec/test_util.moon @@ -1,21 +1,3 @@ --- relative imports -_G.relative = do - _require = require - - (base, sub) -> - sub = sub or 0 - - for i=1, sub - base = base\match '^(.*)%.%w+$' - - (name, x) -> - if name == '.' - name = base - else if '.' == name\sub 1, 1 - name = base .. name - - _require name - sort2 = (a, b) -> {ax, ay}, {bx, by} = a, b "#{ax}//#{ay}" < "#{bx}//#{by}" -- cgit v1.2.3