Renamed network test components
Using `test` shortens paths used by cabal and helps to avoid to long paths on Windows.
Using `test` shortens paths used by cabal and helps to avoid to long paths on Windows.
- name: Win32-network [test]
if: matrix.os == 'windows-latest'
run: cabal --builddir="$CABAL_BUILDDIR" run test-Win32-network
run: cabal --builddir="$CABAL_BUILDDIR" run Win32-network:test
- name: ntp-client [test]
run: cabal --builddir="$CABAL_BUILDDIR" run test-ntp-client
run: cabal --builddir="$CABAL_BUILDDIR" run ntp-client:test
- name: io-sim [test]
run: cabal --builddir="$CABAL_BUILDDIR" run test-sim
run: cabal --builddir="$CABAL_BUILDDIR" run io-sim:test
- name: typed-protocols-examples [test]
run: cabal --builddir="$CABAL_BUILDDIR" run typed-protocols-tests
run: cabal --builddir="$CABAL_BUILDDIR" run typed-protocols-examples:tests
- name: network-mux [test]
run: cabal --builddir="$CABAL_BUILDDIR" run test-network-mux
run: cabal --builddir="$CABAL_BUILDDIR" run network-mux:test
# issue: #1818
- name: ourobors-network-framework [test]
run: cabal --builddir="$CABAL_BUILDDIR" run ouroboros-network-framework-tests -- -p '$0 != "typed-protocols.Socket.socket send receive IPv4"'
run: cabal --builddir="$CABAL_BUILDDIR" run ouroboros-network-framework:test -- -p '$0 != "typed-protocols.Socket.socket send receive IPv4"'
- name: ouroboros-network [test]
run: cabal --builddir="$CABAL_BUILDDIR" run test-network
run: cabal --builddir="$CABAL_BUILDDIR" run ouroboros-network:test
# TODO: we need to install the cddl tool
# - name: ouroboros-network [cddl]
ghc-options: -Wall
-threaded
test-suite test-Win32-network
test-suite test
type: exitcode-stdio-1.0
hs-source-dirs: test
main-is: Main.hs
if flag(checktvarinvariant)
cpp-options: -DCHECK_TVAR_INVARIANT
test-suite test-io-sim-classes
test-suite test
type: exitcode-stdio-1.0
hs-source-dirs: test
main-is: Main.hs
if flag(asserts)
ghc-options: -fno-ignore-asserts
test-suite test-sim
test-suite test
type: exitcode-stdio-1.0
hs-source-dirs: test
main-is: Main.hs
-Wredundant-constraints
-Wno-unticked-promoted-constructors
test-suite test-network-mux
test-suite test
type: exitcode-stdio-1.0
hs-source-dirs: test
main-is: Main.hs
})
({ pkgs, ... }: lib.mkIf (!pkgs.stdenv.hostPlatform.isWindows) {
packages.ouroboros-network.flags.cddl = true;
packages.ouroboros-network.components.tests.test-cddl.build-tools = [pkgs.cddl pkgs.cbor-diag];
packages.ouroboros-network.components.tests.test-cddl.preCheck = "export HOME=`pwd`";
packages.ouroboros-network.components.tests.cddl.build-tools = [pkgs.cddl pkgs.cbor-diag];
packages.ouroboros-network.components.tests.cddl.preCheck = "export HOME=`pwd`";
})
];
configureArgs = lib.optionalString stdenv.hostPlatform.isWindows "--disable-tests";
-Wredundant-constraints
default-extensions: GeneralizedNewtypeDeriving
test-suite test-ntp-client
test-suite test
hs-source-dirs: test, src
main-is: Test.hs
other-modules: Network.NTP.Client.Packet
-Wredundant-constraints
-Wno-unticked-promoted-constructors
test-suite ouroboros-network-framework-tests
test-suite test
type: exitcode-stdio-1.0
main-is: Main.hs
hs-source-dirs: test
ghc-options: -Wall
-Wno-unticked-promoted-constructors
test-suite test-network
test-suite test
type: exitcode-stdio-1.0
hs-source-dirs: test
main-is: Main.hs
if flag(ipv6)
cpp-options: -DOUROBOROS_NETWORK_IPV6
test-suite test-cddl
test-suite cddl
type: exitcode-stdio-1.0
hs-source-dirs: test-cddl
main-is: Main.hs
-Widentities
-Wredundant-constraints
test-suite typed-protocols-tests
test-suite test
type: exitcode-stdio-1.0
main-is: Main.hs
hs-source-dirs: test
In response to review feedback: https://github.com/input-output-hk/cardano-wallet/pull/2451#discussion_r561029734
In response to review feedback: https://github.com/input-output-hk/cardano-wallet/pull/2451#discussion_r560856424
https://github.com/input-output-hk/cardano-haskell/pull/38
Needs latest prettyprinter version.
Needs latest prettyprinter version.
https://github.com/input-output-hk/cardano-haskell/pull/38
In response to review feedback: https://github.com/input-output-hk/cardano-wallet/pull/2451#discussion_r561029734
Three changes that the hydra eval faster. In order of importance: 1) Split `native` jobs into `linux` and `darwin` Reduces the number of times hydra restarts the eval process because memory is running low. When both linux and darwin versions are in the same attribute the evaluation runs out of memory more often as it alternates between evaluating linux and darwin jobs. Grouping all the linux and darwin jobs together reduces the number of times the memory limit is reached. This is makes the "no change" eval more than 4x faster (270s vs 1300s). 2) Avoid duplicate `cabal configure` To get a list of package names in the project we call `cabalProject`, before using those names to provide the overrides for another call to `cabalProject`. `cabalProjectLocal` is not the same for the two calls and as a result `cabal configure` is run twice (and it is very slow for this project. Passing the same `cabalProjectLocal` value to both calls should improve evaluation greatly when changes are made to the `cabal.project` or `.cabal` files. 3) Include jobs to pin plan-nix Pinning the `plan-nix` output means it is copied to the hydra cache. This may not improve eval on the hydra machine itself, it will make testing evaluation on other machines faster (since they will have access to the cached plans).
In response to review feedback: https://github.com/input-output-hk/cardano-wallet/pull/2451#discussion_r560856424