dmp1ce / haskell-libsodium Goto Github PK
View Code? Open in Web Editor NEWHaskell bindings for libsodium
License: The Unlicense
Haskell bindings for libsodium
License: The Unlicense
MacOS, Xcode-9.3, GHC-8.2.2:
$ stack test
bindings-libsodium-0.1.0.0: unregistering (missing dependencies: Glob, QuickCheck, doctest, tasty, tasty-hunit, tasty-quickcheck, text)
base-compat-0.9.3: configure
async-2.1.1.1: download
base-compat-0.9.3: build
code-page-0.1.3: configure
code-page-0.1.3: build
clock-0.7.2: configure
code-page-0.1.3: copy/register
clock-0.7.2: build
async-2.1.1.1: configure
async-2.1.1.1: build
colour-2.3.4: configure
base-compat-0.9.3: copy/register
dlist-0.8.0.4: download
colour-2.3.4: build
dlist-0.8.0.4: configure
clock-0.7.2: copy/register
async-2.1.1.1: copy/register
dlist-0.8.0.4: build
ghc-paths-0.1.0.9: configure
mtl-2.2.2: download
dlist-0.8.0.4: copy/register
Glob-0.9.2: download
ghc-paths-0.1.0.9: build
mtl-2.2.2: configure
ghc-paths-0.1.0.9: copy/register
doctest-0.13.0: download
mtl-2.2.2: build
Glob-0.9.2: configure
colour-2.3.4: copy/register
ansi-terminal-0.8.0.2: download
Glob-0.9.2: build
doctest-0.13.0: configure
doctest-0.13.0: build
ansi-terminal-0.8.0.2: configure
ansi-terminal-0.8.0.2: build
mtl-2.2.2: copy/register
primitive-0.6.3.0: download
primitive-0.6.3.0: configure
Glob-0.9.2: copy/register
primitive-0.6.3.0: build
text-1.2.3.0: download
text-1.2.3.0: configure
text-1.2.3.0: build
ansi-terminal-0.8.0.2: copy/register
ansi-wl-pprint-0.6.8.2: download
ansi-wl-pprint-0.6.8.2: configure
ansi-wl-pprint-0.6.8.2: build
ansi-wl-pprint-0.6.8.2: copy/register
optparse-applicative-0.14.2.0: download
optparse-applicative-0.14.2.0: configure
optparse-applicative-0.14.2.0: build
primitive-0.6.3.0: copy/register
tf-random-0.5: download
tf-random-0.5: configure
doctest-0.13.0: copy/register
tf-random-0.5: build
unbounded-delays-0.1.1.0: configure
unbounded-delays-0.1.1.0: build
unbounded-delays-0.1.1.0: copy/register
tf-random-0.5: copy/register
QuickCheck-2.10.1: download
QuickCheck-2.10.1: configure
QuickCheck-2.10.1: build
optparse-applicative-0.14.2.0: copy/register
tasty-1.0.1.1: download
tasty-1.0.1.1: configure
tasty-1.0.1.1: build
tasty-1.0.1.1: copy/register
tasty-hunit-0.10.0.1: download
tasty-hunit-0.10.0.1: configure
tasty-hunit-0.10.0.1: build
tasty-hunit-0.10.0.1: copy/register
QuickCheck-2.10.1: copy/register
tasty-quickcheck-0.9.2: download
tasty-quickcheck-0.9.2: configure
tasty-quickcheck-0.9.2: build
tasty-quickcheck-0.9.2: copy/register
text-1.2.3.0: copy/register
bindings-libsodium-0.1.0.0: configure (lib + test)
Configuring bindings-libsodium-0.1.0.0...
bindings-libsodium-0.1.0.0: build (lib + test)
Preprocessing library for bindings-libsodium-0.1.0.0..
Building library for bindings-libsodium-0.1.0.0..
[1 of 2] Compiling Bindings.LibSodium ( .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/Bindings/LibSodium.hs, .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/Bindings/LibSodium.o )
[2 of 2] Compiling Crypto.LibSodium ( src/Crypto/LibSodium.hs, .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/Crypto/LibSodium.o )
Preprocessing test suite 'libsodium-test' for bindings-libsodium-0.1.0.0..
Building test suite 'libsodium-test' for bindings-libsodium-0.1.0.0..
[1 of 4] Compiling TestHelpers ( src-test/TestHelpers.hs, .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/libsodium-test/libsodium-test-tmp/TestHelpers.o )
[2 of 4] Compiling HighLevelTests ( src-test/HighLevelTests.hs, .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/libsodium-test/libsodium-test-tmp/HighLevelTests.o )
[3 of 4] Compiling BindingTests ( src-test/BindingTests.hs, .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/libsodium-test/libsodium-test-tmp/BindingTests.o )
[4 of 4] Compiling Main ( src-test/Main.hs, .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/libsodium-test/libsodium-test-tmp/Main.o )
Linking .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/libsodium-test/libsodium-test ...
Preprocessing test suite 'libsodium-doctest' for bindings-libsodium-0.1.0.0..
Building test suite 'libsodium-doctest' for bindings-libsodium-0.1.0.0..
[1 of 1] Compiling Main ( src-doctest/Main.hs, .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/libsodium-doctest/libsodium-doctest-tmp/Main.o )
Linking .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/libsodium-doctest/libsodium-doctest ...
bindings-libsodium-0.1.0.0: copy/register
Installing library in /Users/uri/src/haskell-libsodium/.stack-work/install/x86_64-osx/lts-11.5/8.2.2/lib/x86_64-osx-ghc-8.2.2/bindings-libsodium-0.1.0.0-JyTvnR9M6Z05zAdTw7NKwf
Registering library for bindings-libsodium-0.1.0.0..
bindings-libsodium-0.1.0.0: test (suite: libsodium-doctest)
Progress: 22/23Examples: 0 Tried: 0 Errors: 0 Failures: 0
bindings-libsodium-0.1.0.0: Test suite libsodium-doctest passed
bindings-libsodium-0.1.0.0: test (suite: libsodium-test)
all-tests
Unit_tests_bindings
c'sodium_init: OK
c'sodium_memcmp: OK
c'sodium_bin2hex: OK
+++ OK, passed 100 tests.
c'sodium_hex2bin: OK (0.02s)
+++ OK, passed 100 tests.
hex2bin_bin2hex: OK
+++ OK, passed 100 tests.
c'sodium_increment: OK
c'sodium_add: OK
c'sodium_compare: OK
c'sodium_is_zero: OK
c'sodium_memzero: OK
c'sodium_mlock: OK
c'sodium_allocarray: OK
c'sodium_mprotect: OK
c'sodium_allocarray_crash: FAIL (1.37s)
src-test/BindingTests.hs:323:
expected: -11
but got: -10
c'sodium_mprotect_noaccess_crash: FAIL (1.39s)
src-test/BindingTests.hs:323:
expected: -11
but got: -10
c'sodium_mprotect_readonly_crash: FAIL (1.38s)
src-test/BindingTests.hs:323:
expected: -11
but got: -10
c'randombytes_random: OK
c'randombytes_uniform: OK
c'randombytes_buf: OK
c'randombytes_stir: OK
c'crypto_secretbox_easy: OK
+++ OK, passed 100 tests.
c'crypto_secretbox_detached: OK
+++ OK, passed 100 tests.
c'crypto_scalarmult_base: OK (0.02s)
+++ OK, passed 100 tests.
Unit_tests_high-level
sodiumInit: OK
sodiumMemcmp: OK
sodiumBin2Hex: OK
+++ OK, passed 100 tests.
sodiumHex2Bin: OK
+++ OK, passed 100 tests.
sodiumHex2Bin_Bin2Hex: OK
+++ OK, passed 100 tests.
sodiumIncrement: OK
sodiumAdd: OK
sodiumCompare: OK
sodiumIsZero: OK
sodiumMemZero: OK
sodiumMLock: OK
sodiumAllocArray: OK
sodiumMProtect: OK
randomBytesRandom: OK
randomBytesUniform: OK
randomBytesBuf: OK
randomBytesStir: OK
cryptoSecretBoxEasy: OK (0.01s)
+++ OK, passed 100 tests.
cryptoSecretBoxDetached: OK (0.07s)
+++ OK, passed 100 tests.
3 out of 42 tests failed (1.39s)
bindings-libsodium-0.1.0.0: Test suite libsodium-test failed
Completed 23 action(s).
Test suite failure for package bindings-libsodium-0.1.0.0
libsodium-test: exited with: ExitFailure 1
Logs printed to console
$ ghc --version
The Glorious Glasgow Haskell Compilation System, version 8.2.2
$ stack --version
Version 1.6.5, Git revision 24ab0d6ff07f28276e082c3ce74dfdeb1a2ca9e9 (5514 commits) x86_64 hpack-0.20.0
$ cabal --version
cabal-install version 2.0.0.1
compiled using version 2.0.1.1 of the Cabal library
$ $ cat /opt/local/include/sodium/version.h | fgrep VERSION
#define SODIUM_VERSION_STRING "1.0.16"
#define SODIUM_LIBRARY_VERSION_MAJOR 10
#define SODIUM_LIBRARY_VERSION_MINOR 1
$
Write a QuickCheck test to try and make the test fail more often.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.