mesa_test 0.2.13 → 0.2.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/mesa_test.rb +8 -3
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a8ff8b82b3655937a7775337f4b9a66c910990c0ed35fbf9f2c1b63e4392f2fd
4
- data.tar.gz: 4b1ac8783b4c5a107500657419ef59d7e1e6cd07eac95f8e73e5bfd8136b804e
3
+ metadata.gz: dc1b9c24edbaf3b60ef4810d6ac67dfeeffea731ce7fd2fac594fad6e58912da
4
+ data.tar.gz: 05427526f0ff36f357c0d93fdf98d65bf25b38d7f4c238555ca3f86b5127a899
5
5
  SHA512:
6
- metadata.gz: 97bdd12698d20b729189bec25da248627ee4a65bc7586cef231e8f1db4648f38fccddb7db68df7434f1123c2098e09776cbc67fb1de5bedc914b7496740a0432
7
- data.tar.gz: 403d73e25b4f1697fc1299965b109bb34f0686b482aebb895bb686ef3618688174effa9f0ff2268f7436f21c87579e6683dccfff67746be8254ff43cab67651a
6
+ metadata.gz: 68989aaa1d18b36568fac9dd3cb275055b926e98792a1a0456b0e5318baab902eb2a483d52b5954deb14cbb9123a20482dc4f78ec57b196382be79c9f24ba4fb
7
+ data.tar.gz: ff9985cd7edc8bd201626e701eb01344abea2516f29802ed7740049ec142f0b51e3912725b820236dd074388a6c893be23104d9b46e2e16ae92a4dcf36e7e32c
data/lib/mesa_test.rb CHANGED
@@ -822,7 +822,7 @@ class Mesa
822
822
  def check_mesa_dir
823
823
  res = File.exist?(File.join(mesa_dir, 'data', 'version_number'))
824
824
  MesaTestCase.modules.each do |mod|
825
- res &&= File.directory?(test_suite_dir(mod: mod))
825
+ res &&= dir_or_symlink_exists?(test_suite_dir(mod: mod))
826
826
  end
827
827
  res
828
828
  end
@@ -1265,7 +1265,7 @@ class MesaTestCase
1265
1265
  # make sure that we can get to the test case directory. Throw an exception
1266
1266
  # if we cannot
1267
1267
  def check_test_case
1268
- return if File.directory? test_case_dir
1268
+ return if dir_or_symlink_exists? test_case_dir
1269
1269
  raise TestCaseDirError, "No such test case: #{test_case_dir}."
1270
1270
  end
1271
1271
 
@@ -1273,7 +1273,7 @@ class MesaTestCase
1273
1273
  # directory
1274
1274
  def check_mesa_dir
1275
1275
  is_valid = File.exist?(File.join(mesa_dir, 'data', 'version_number')) &&
1276
- File.directory?(test_suite_dir)
1276
+ dir_or_symlink_exists?(test_suite_dir)
1277
1277
  raise MesaDirError, "Invalid MESA dir: #{mesa_dir}" unless is_valid
1278
1278
  end
1279
1279
 
@@ -1648,6 +1648,11 @@ def generate_seeds_rb(mesa_dir, outfile)
1648
1648
  end
1649
1649
  end
1650
1650
 
1651
+ # Check if path is directory or symlink
1652
+ def dir_or_symlink_exists?(path)
1653
+ File.directory?(path) || File.symlink?(path)
1654
+ end
1655
+
1651
1656
  # force the execution to happen with bash
1652
1657
  def bash_execute(command)
1653
1658
  system('bash -c "' + command + '"')
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mesa_test
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.13
4
+ version: 0.2.14
5
5
  platform: ruby
6
6
  authors:
7
7
  - William Wolf
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-04-27 00:00:00.000000000 Z
11
+ date: 2020-05-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json