mirror of
https://github.com/ACINQ/eclair.git
synced 2025-02-24 06:47:46 +01:00
This PR does two main things: - introduce a new `FixtureSpec` base class for tests that involve a fixture. See the scaladoc for more info. - add new simple integration tests in package `integration.basic`. They are based on `MinimalNodeFixture`, which is a full setup for a node with real actors, except the bitcoin part (watcher/wallet) which is mocked. They are much lighter than our previous integration tests, which allow us to keep each test individual, as opposed to having all tests of the same suite depend on each other. We can define more complex fixtures with any number of nodes. Other minor improvements: - update scalatest version - simplify `ChannelStateTestsHelperMethods` - replace all === by == Triple equals allows customizing the equality method, but we never use that. Detailed errors (which is what we were looking for) are provided by mixing in scalatest's `Assertions` and using the regular `assert(x==y)` syntax. The `Assertions` trait is already mixed in by default in all scalatest suites.
315 lines
12 KiB
XML
315 lines
12 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!--
|
|
~ Copyright 2019 ACINQ SAS
|
|
~
|
|
~ Licensed under the Apache License, Version 2.0 (the "License");
|
|
~ you may not use this file except in compliance with the License.
|
|
~ You may obtain a copy of the License at
|
|
~
|
|
~ http://www.apache.org/licenses/LICENSE-2.0
|
|
~
|
|
~ Unless required by applicable law or agreed to in writing, software
|
|
~ distributed under the License is distributed on an "AS IS" BASIS,
|
|
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
~ See the License for the specific language governing permissions and
|
|
~ limitations under the License.
|
|
-->
|
|
|
|
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
|
<modelVersion>4.0.0</modelVersion>
|
|
<parent>
|
|
<groupId>fr.acinq.eclair</groupId>
|
|
<artifactId>eclair_2.13</artifactId>
|
|
<version>0.7.1-SNAPSHOT</version>
|
|
</parent>
|
|
|
|
<artifactId>eclair-core_2.13</artifactId>
|
|
<packaging>jar</packaging>
|
|
|
|
<name>${project.artifactId}</name>
|
|
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>com.googlecode.maven-download-plugin</groupId>
|
|
<artifactId>download-maven-plugin</artifactId>
|
|
<version>1.3.0</version>
|
|
<executions>
|
|
<execution>
|
|
<id>download-bitcoind</id>
|
|
<phase>generate-test-resources</phase>
|
|
<goals>
|
|
<goal>wget</goal>
|
|
</goals>
|
|
<configuration>
|
|
<skip>${maven.test.skip}</skip>
|
|
<url>${bitcoind.url}</url>
|
|
<unpack>true</unpack>
|
|
<outputDirectory>${project.build.directory}</outputDirectory>
|
|
<md5>${bitcoind.md5}</md5>
|
|
<sha1>${bitcoind.sha1}</sha1>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-jar-plugin</artifactId>
|
|
<configuration>
|
|
<archive>
|
|
<manifest>
|
|
<addClasspath>true</addClasspath>
|
|
<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
|
|
</manifest>
|
|
<manifestEntries>
|
|
<!-- we hide the git commit in the Specification-Version standard field-->
|
|
<Specification-Version>${git.commit.id}</Specification-Version>
|
|
<Url>${project.parent.url}</Url>
|
|
</manifestEntries>
|
|
</archive>
|
|
</configuration>
|
|
<executions>
|
|
<execution>
|
|
<goals>
|
|
<goal>test-jar</goal>
|
|
</goals>
|
|
<phase>test-compile</phase>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
|
|
<profiles>
|
|
<profile>
|
|
<id>default</id>
|
|
<activation>
|
|
<activeByDefault>true</activeByDefault>
|
|
</activation>
|
|
<properties>
|
|
<bitcoind.url>https://bitcoincore.org/bin/bitcoin-core-0.21.1/bitcoin-0.21.1-x86_64-linux-gnu.tar.gz</bitcoind.url>
|
|
<bitcoind.md5>e283a98b5e9f0b58e625e1dde661201d</bitcoind.md5>
|
|
<bitcoind.sha1>5101e29b39c33cc8e40d5f3b46dda37991b037a0</bitcoind.sha1>
|
|
</properties>
|
|
</profile>
|
|
<profile>
|
|
<id>Mac</id>
|
|
<activation>
|
|
<os>
|
|
<family>mac</family>
|
|
</os>
|
|
</activation>
|
|
<properties>
|
|
<bitcoind.url>https://bitcoincore.org/bin/bitcoin-core-0.21.1/bitcoin-0.21.1-osx64.tar.gz</bitcoind.url>
|
|
<bitcoind.md5>dfd1f323678eede14ae2cf6afb26ff6a</bitcoind.md5>
|
|
<bitcoind.sha1>4273696f90a2648f90142438221f5d1ade16afa2</bitcoind.sha1>
|
|
</properties>
|
|
</profile>
|
|
<profile>
|
|
<id>Windows</id>
|
|
<activation>
|
|
<os>
|
|
<family>Windows</family>
|
|
</os>
|
|
</activation>
|
|
<properties>
|
|
<bitcoind.url>https://bitcoincore.org/bin/bitcoin-core-0.21.1/bitcoin-0.21.1-win64.zip</bitcoind.url>
|
|
<bitcoind.md5>1c6f5081ea68dcec7eddb9e6cdfc508d</bitcoind.md5>
|
|
<bitcoind.sha1>a782cd413fc736f05fad3831d6a9f59dde779520</bitcoind.sha1>
|
|
</properties>
|
|
</profile>
|
|
</profiles>
|
|
|
|
<dependencies>
|
|
<dependency>
|
|
<groupId>org.scala-lang.modules</groupId>
|
|
<artifactId>scala-collection-contrib_${scala.version.short}</artifactId>
|
|
<version>0.2.1</version>
|
|
</dependency>
|
|
<!-- AKKA -->
|
|
<dependency>
|
|
<groupId>com.typesafe.akka</groupId>
|
|
<artifactId>akka-actor_${scala.version.short}</artifactId>
|
|
<version>${akka.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.typesafe.akka</groupId>
|
|
<artifactId>akka-actor-typed_${scala.version.short}</artifactId>
|
|
<version>${akka.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.typesafe.akka</groupId>
|
|
<artifactId>akka-slf4j_${scala.version.short}</artifactId>
|
|
<version>${akka.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.typesafe.akka</groupId>
|
|
<artifactId>akka-cluster_${scala.version.short}</artifactId>
|
|
<version>${akka.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.typesafe.akka</groupId>
|
|
<artifactId>akka-cluster-typed_${scala.version.short}</artifactId>
|
|
<version>${akka.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.typesafe.akka</groupId>
|
|
<artifactId>akka-cluster-tools_${scala.version.short}</artifactId>
|
|
<version>${akka.version}</version>
|
|
</dependency>
|
|
<!-- HTTP CLIENT -->
|
|
<dependency>
|
|
<groupId>com.softwaremill.sttp.client3</groupId>
|
|
<artifactId>okhttp-backend_${scala.version.short}</artifactId>
|
|
<version>${sttp.version}</version>
|
|
<exclusions>
|
|
<exclusion>
|
|
<groupId>org.jetbrains.kotlin</groupId>
|
|
<artifactId>kotlin-stdlib</artifactId>
|
|
</exclusion>
|
|
</exclusions>
|
|
</dependency>
|
|
<!-- JSON -->
|
|
<dependency>
|
|
<groupId>org.json4s</groupId>
|
|
<artifactId>json4s-jackson_${scala.version.short}</artifactId>
|
|
<version>4.0.3</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.softwaremill.sttp.client3</groupId>
|
|
<artifactId>json4s_${scala.version.short}</artifactId>
|
|
<version>${sttp.version}</version>
|
|
</dependency>
|
|
<!-- TCP -->
|
|
<dependency>
|
|
<groupId>io.netty</groupId>
|
|
<artifactId>netty-all</artifactId>
|
|
<version>4.1.42.Final</version>
|
|
</dependency>
|
|
<!-- BITCOIN -->
|
|
<dependency>
|
|
<groupId>fr.acinq</groupId>
|
|
<artifactId>bitcoin-lib_${scala.version.short}</artifactId>
|
|
<version>${bitcoinlib.version}</version>
|
|
<exclusions>
|
|
<exclusion>
|
|
<groupId>com.google.protobuf</groupId>
|
|
<artifactId>protobuf-java</artifactId>
|
|
</exclusion>
|
|
</exclusions>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.zeromq</groupId>
|
|
<artifactId>jeromq</artifactId>
|
|
<version>0.5.2</version>
|
|
</dependency>
|
|
<!-- SERIALIZATION -->
|
|
<dependency>
|
|
<groupId>org.scodec</groupId>
|
|
<artifactId>scodec-core_${scala.version.short}</artifactId>
|
|
<version>1.11.9</version>
|
|
</dependency>
|
|
<dependency>
|
|
<!-- needed to fix "No implicit Ordering defined for scodec.bits.ByteVector" -->
|
|
<groupId>org.scodec</groupId>
|
|
<artifactId>scodec-bits_${scala.version.short}</artifactId>
|
|
<version>1.1.30</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>commons-codec</groupId>
|
|
<artifactId>commons-codec</artifactId>
|
|
<version>1.9</version>
|
|
</dependency>
|
|
<!-- LOGGING -->
|
|
<dependency>
|
|
<groupId>org.clapper</groupId>
|
|
<artifactId>grizzled-slf4j_${scala.version.short}</artifactId>
|
|
<version>1.3.4</version>
|
|
</dependency>
|
|
<!-- OTHER -->
|
|
<dependency>
|
|
<groupId>org.jheaps</groupId>
|
|
<artifactId>jheaps</artifactId>
|
|
<version>0.9</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.xerial</groupId>
|
|
<artifactId>sqlite-jdbc</artifactId>
|
|
<version>3.36.0.1</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.postgresql</groupId>
|
|
<artifactId>postgresql</artifactId>
|
|
<version>42.3.3</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.zaxxer</groupId>
|
|
<artifactId>HikariCP</artifactId>
|
|
<version>3.4.2</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.bouncycastle</groupId>
|
|
<artifactId>bcprov-jdk15on</artifactId>
|
|
<version>1.68</version>
|
|
</dependency>
|
|
<dependency>
|
|
<!-- This is to get rid of '[WARNING] warning: Class javax.annotation.Nonnull not found - continuing with a stub.' compile errors -->
|
|
<groupId>com.google.code.findbugs</groupId>
|
|
<artifactId>jsr305</artifactId>
|
|
<version>3.0.2</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.google.guava</groupId>
|
|
<artifactId>guava</artifactId>
|
|
<version>${guava.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.softwaremill.quicklens</groupId>
|
|
<artifactId>quicklens_${scala.version.short}</artifactId>
|
|
<version>1.5.0</version>
|
|
</dependency>
|
|
<!-- MONITORING -->
|
|
<dependency>
|
|
<groupId>io.kamon</groupId>
|
|
<artifactId>kamon-core_${scala.version.short}</artifactId>
|
|
<version>${kamon.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>io.kamon</groupId>
|
|
<artifactId>kamon-akka_${scala.version.short}</artifactId>
|
|
<version>${kamon.version}</version>
|
|
</dependency>
|
|
<!-- TESTS -->
|
|
<dependency>
|
|
<groupId>com.typesafe.akka</groupId>
|
|
<artifactId>akka-testkit_${scala.version.short}</artifactId>
|
|
<version>${akka.version}</version>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.typesafe.akka</groupId>
|
|
<artifactId>akka-actor-testkit-typed_${scala.version.short}</artifactId>
|
|
<version>${akka.version}</version>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>ch.qos.logback</groupId>
|
|
<artifactId>logback-classic</artifactId>
|
|
<version>1.2.3</version>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.mockito</groupId>
|
|
<artifactId>mockito-scala-scalatest_${scala.version.short}</artifactId>
|
|
<version>1.17.5</version>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.opentable.components</groupId>
|
|
<artifactId>otj-pg-embedded</artifactId>
|
|
<version>0.13.3</version>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
</dependencies>
|
|
</project>
|