diff options
author | Oleh Prypin <blaxpirit@gmail.com> | 2015-04-21 14:37:29 +0300 |
---|---|---|
committer | Oleh Prypin <blaxpirit@gmail.com> | 2015-04-21 14:37:29 +0300 |
commit | 32109a7867b06cdf9e66ad717f42aebb3e0fcaa4 (patch) | |
tree | 6d36a5dfe0007bc7529aeda7acf18bd3c29257ee /lib/pure/xmlparser.nim | |
parent | d203d6fad44547d2291e33712057d154e18c0361 (diff) | |
download | Nim-32109a7867b06cdf9e66ad717f42aebb3e0fcaa4.tar.gz |
Don't run non-test code when defined(testing)
Diffstat (limited to 'lib/pure/xmlparser.nim')
-rw-r--r-- | lib/pure/xmlparser.nim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/pure/xmlparser.nim b/lib/pure/xmlparser.nim index 755bfcdbc..840cae734 100644 --- a/lib/pure/xmlparser.nim +++ b/lib/pure/xmlparser.nim @@ -143,7 +143,7 @@ proc loadXml*(path: string): XmlNode = result = loadXml(path, errors) if errors.len > 0: raiseInvalidXml(errors) -when isMainModule: +when not defined(testing) and isMainModule: import os var errors: seq[string] = @[] |