Migrate to `unittest2` (#125)
* Migrate to `unittest2` why: Global symbol overflow when running NIM 1.2 on Github ci suggests that unit tests run sort of separately. The replacement library `unittest2` provides that. * Build ci dependencies
This commit is contained in:
parent
4cab7b0879
commit
9c3596d9de
|
@ -155,6 +155,7 @@ jobs:
|
|||
fi
|
||||
nim --version
|
||||
nimble --version
|
||||
nimble install -y --depsOnly
|
||||
env TEST_LANG=c nimble test
|
||||
env TEST_LANG=cpp nimble test
|
||||
|
||||
|
@ -173,5 +174,6 @@ jobs:
|
|||
- name: Test using VCC
|
||||
if: runner.os == 'Windows'
|
||||
run: |
|
||||
nimble install -y --depsOnly
|
||||
env TEST_LANG=c nimble testvcc
|
||||
env TEST_LANG=cpp nimble testvcc
|
||||
|
|
|
@ -7,7 +7,8 @@ description = "Backports, standard library candidates and small utilities that
|
|||
license = "Apache License 2.0"
|
||||
skipDirs = @["tests"]
|
||||
|
||||
requires "nim >= 1.2.0"
|
||||
requires "nim >= 1.2.0",
|
||||
"unittest2"
|
||||
|
||||
### Helper functions
|
||||
proc test(args, path: string) =
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import
|
||||
random, unittest,
|
||||
random, unittest2,
|
||||
../../stew/ranges/bitranges, ../../stew/bitseqs
|
||||
|
||||
proc randomBytes(n: int): seq[byte] =
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import
|
||||
unittest, math,
|
||||
unittest2, math,
|
||||
../../stew/ptrops,
|
||||
../../stew/ranges/[stackarrays]
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import
|
||||
unittest, sets,
|
||||
unittest2, sets,
|
||||
../../stew/ranges/[typedranges, ptr_arith]
|
||||
|
||||
suite "Typed ranges":
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
{.used.}
|
||||
|
||||
import
|
||||
std/unittest,
|
||||
unittest2,
|
||||
../stew/arrayops
|
||||
|
||||
suite "arrayops":
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import
|
||||
std/unittest,
|
||||
unittest2,
|
||||
../stew/assign2
|
||||
|
||||
suite "assign2":
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import unittest
|
||||
import unittest2
|
||||
import ../stew/base10
|
||||
|
||||
when defined(nimHasUsed): {.used.}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import unittest
|
||||
import unittest2
|
||||
import ../stew/base32
|
||||
|
||||
when defined(nimHasUsed): {.used.}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import unittest
|
||||
import unittest2
|
||||
import ../stew/base58
|
||||
|
||||
when defined(nimHasUsed): {.used.}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import unittest
|
||||
import unittest2
|
||||
import ../stew/[base64, byteutils]
|
||||
|
||||
when defined(nimHasUsed): {.used.}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import unittest
|
||||
import unittest2
|
||||
|
||||
import ../stew/bitops2
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import
|
||||
unittest, strformat,
|
||||
unittest2, strformat,
|
||||
../stew/[bitseqs]
|
||||
|
||||
suite "Bit fields":
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
# at your option. This file may not be copied, modified, or distributed except according to those terms.
|
||||
|
||||
import
|
||||
std/unittest,
|
||||
unittest2,
|
||||
../stew/byteutils
|
||||
|
||||
proc compilationTest {.exportc: "compilationTest".} =
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import unittest
|
||||
import unittest2
|
||||
import ../stew/ctops
|
||||
|
||||
suite "Constant-time operations test suite":
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import unittest
|
||||
import unittest2
|
||||
|
||||
import ../stew/endians2
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
# distributed except according to those terms.
|
||||
|
||||
import
|
||||
std/unittest,
|
||||
unittest2,
|
||||
../stew/interval_set
|
||||
|
||||
const
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import unittest
|
||||
import unittest2
|
||||
import ../stew/io2
|
||||
|
||||
suite "OS Input/Output procedures test suite":
|
||||
|
|
|
@ -9,7 +9,8 @@
|
|||
# according to those terms.
|
||||
|
||||
import
|
||||
std/[algorithm, sequtils, strformat, strutils, tables, unittest],
|
||||
std/[algorithm, sequtils, strformat, strutils, tables],
|
||||
unittest2,
|
||||
../stew/keyed_queue,
|
||||
../stew/keyed_queue/kq_debug
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import
|
||||
unittest, random,
|
||||
unittest2, random,
|
||||
../stew/[byteutils, leb128, results]
|
||||
|
||||
const edgeValues = {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import
|
||||
unittest,
|
||||
unittest2,
|
||||
../stew/shims/macros
|
||||
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import
|
||||
unittest, typetraits,
|
||||
unittest2, typetraits,
|
||||
../stew/objects
|
||||
|
||||
when defined(nimHasUsed):
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
#
|
||||
# at your option. This file may not be copied, modified, or distributed except according to those terms.
|
||||
|
||||
import unittest
|
||||
import unittest2
|
||||
|
||||
import ../stew/ptrops
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
# at your option. This file may not be copied, modified, or distributed except according to those terms.
|
||||
|
||||
import
|
||||
std/unittest,
|
||||
unittest2,
|
||||
../stew/sequtils2
|
||||
|
||||
suite "sequtils2":
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import
|
||||
unittest,
|
||||
unittest2,
|
||||
../stew/shims/sets
|
||||
|
||||
suite "shims/sets":
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
import
|
||||
std/[algorithm, sequtils, strformat, tables],
|
||||
../stew/sorted_set,
|
||||
unittest
|
||||
unittest2
|
||||
|
||||
const
|
||||
keyList = [
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import
|
||||
unittest,
|
||||
unittest2,
|
||||
../stew/templateutils
|
||||
|
||||
var computations = newSeq[string]()
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import
|
||||
unittest, random,
|
||||
unittest2, random,
|
||||
../stew/[varints, byteutils]
|
||||
|
||||
const edgeValues = {
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import std/unittest
|
||||
import unittest2
|
||||
import ../stew/io2
|
||||
|
||||
when defined(windows):
|
||||
|
|
Loading…
Reference in New Issue