mirror of
https://github.com/status-im/nim-confutils.git
synced 2025-03-02 12:50:31 +00:00
use --mm: instead of --gc: and remove stddefects import (#85)
* use --mm: instead of --gc: and remove stddefects import * remove incorrect trailing ":" from line
This commit is contained in:
parent
1f3acaf6e9
commit
10e53c3a67
8
.github/workflows/ci.yml
vendored
8
.github/workflows/ci.yml
vendored
@ -158,12 +158,12 @@ jobs:
|
||||
nimble install -y --depsOnly
|
||||
nimble install -y toml_serialization json_serialization unittest2
|
||||
rm -f nimble.lock
|
||||
env NIMFLAGS="${NIMFLAGS} --gc:refc" nimble test
|
||||
env NIMFLAGS="${NIMFLAGS} --mm:refc" nimble test
|
||||
let "linux32= "${{ matrix.target.os }}" == "linux" && "${{ matrix.target.cpu }}" == "i386""
|
||||
if [[ "${{ matrix.branch }}" == "devel" && "$linux32" == 0 ]]; then
|
||||
echo -e "\nTesting with '--gc:orc':\n"
|
||||
if env NIMFLAGS="${NIMFLAGS} --gc:orc" nimble test; then
|
||||
echo "Nim devel with --gc:orc works again! Please remove this check in ci.yml"
|
||||
echo -e "\nTesting with '--mm:orc':\n"
|
||||
if env NIMFLAGS="${NIMFLAGS} --mm:orc" nimble test; then
|
||||
echo "Nim devel with --mm:orc works again! Please remove this check in ci.yml"
|
||||
false
|
||||
fi
|
||||
fi
|
||||
|
@ -17,7 +17,7 @@ func parseCmdArg*(T: type Port, s: string): T =
|
||||
"The supplied port must be an integer value in the range 1-65535")
|
||||
|
||||
var intVal: int
|
||||
let parsedChars = try: parseInt(s, intVal):
|
||||
let parsedChars = try: parseInt(s, intVal)
|
||||
except CatchableError: fail()
|
||||
|
||||
if parsedChars != len(s) or intVal < 1 or intVal > 65535:
|
||||
|
@ -1,5 +1,5 @@
|
||||
# nim-confutils
|
||||
# Copyright (c) 2022 Status Research & Development GmbH
|
||||
# Copyright (c) 2022-2023 Status Research & Development GmbH
|
||||
# Licensed and distributed under either of
|
||||
# * MIT license: [LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT
|
||||
# * Apache License, Version 2.0, ([LICENSE-APACHE](LICENSE-APACHE) or http://www.apache.org/licenses/LICENSE-2.0)
|
||||
@ -10,9 +10,6 @@ import
|
||||
unittest2,
|
||||
../confutils
|
||||
|
||||
{.warning[UnusedImport]:off.}
|
||||
import stew/shims/stddefects
|
||||
|
||||
func testValidValues[T](lo: T = low(T), hi: T = high(T)): bool =
|
||||
allIt(lo .. hi, T.parseCmdArg($it) == it)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user