From b68fcc6bb2c770495ff8e2508c06dfdd49abcc80 Mon Sep 17 00:00:00 2001 From: William Boman Date: Thu, 21 Apr 2022 12:09:59 +0200 Subject: chore: refactor remaining installers to async impl (#616) --- tests/core/managers/gem_spec.lua | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) (limited to 'tests/core/managers/gem_spec.lua') diff --git a/tests/core/managers/gem_spec.lua b/tests/core/managers/gem_spec.lua index beab3968..90d0c390 100644 --- a/tests/core/managers/gem_spec.lua +++ b/tests/core/managers/gem_spec.lua @@ -97,10 +97,11 @@ strscan (default: 3.0.1) assert.spy(spawn.gem).was_called_with(match.tbl_containing { "list", cwd = "/tmp/install/dir", - env = match.all_of( - match.list_containing "GEM_HOME=/tmp/install/dir", - match.list_containing "GEM_PATH=/tmp/install/dir" - ), + env = match.tbl_containing { + GEM_HOME = "/tmp/install/dir", + GEM_PATH = "/tmp/install/dir", + PATH = match.matches "^/tmp/install/dir/bin:.*$", + }, }) assert.is_true(result:is_success()) assert.equals("0.44.0", result:get_or_nil()) @@ -139,10 +140,11 @@ solargraph (0.44.0 < 0.44.3) assert.spy(spawn.gem).was_called_with(match.tbl_containing { "outdated", cwd = "/tmp/install/dir", - env = match.all_of( - match.list_containing "GEM_HOME=/tmp/install/dir", - match.list_containing "GEM_PATH=/tmp/install/dir" - ), + env = match.tbl_containing { + GEM_HOME = "/tmp/install/dir", + GEM_PATH = "/tmp/install/dir", + PATH = match.matches "^/tmp/install/dir/bin:.*$", + }, }) assert.is_true(result:is_success()) assert.equals( -- cgit v1.2.3-70-g09d2