summaryrefslogtreecommitdiff
path: root/Dockerfile_test
diff options
context:
space:
mode:
authorOleg Morozenkov <reo7sp@users.noreply.github.com>2017-01-15 02:01:22 +0300
committerOleg Morozenkov <reo7sp@users.noreply.github.com>2017-01-15 02:01:22 +0300
commitad676623168e7b7b083f66617087c6cf424000d1 (patch)
tree64a893a0c17e2a29c227ebdb53076e40ace19af0 /Dockerfile_test
parentbbf030e1d315d6ba108a75a5ce0113485a2319ba (diff)
Fix tests
Diffstat (limited to 'Dockerfile_test')
-rw-r--r--Dockerfile_test27
1 files changed, 27 insertions, 0 deletions
diff --git a/Dockerfile_test b/Dockerfile_test
new file mode 100644
index 0000000..0d6f409
--- /dev/null
+++ b/Dockerfile_test
@@ -0,0 +1,27 @@
+FROM debian:latest
+MAINTAINER Oleg Morozenkov <a@reo7sp.ru>
+
+RUN apt-get -qq update && \
+ apt-get -qq install -y g++ make binutils cmake libssl-dev libboost-system-dev libboost-iostreams-dev libboost-test-dev
+
+WORKDIR /tmp/tgbot-cpp
+COPY include include
+COPY src src
+COPY test test
+COPY samples samples
+COPY CMakeLists.txt ./
+
+RUN cmake -DENABLE_TESTS=ON . && \
+ make -j4 && \
+ make install
+
+WORKDIR /tmp/tgbot-cpp/samples/echobot
+RUN rm -rf CMakeCache.txt CMakeFiles/ && \
+ cmake . && make -j4
+
+WORKDIR /tmp/tgbot-cpp/samples/inline-keyboard
+RUN rm -rf CMakeCache.txt CMakeFiles/ && \
+ cmake . && make -j4
+
+WORKDIR /tmp/tgbot-cpp
+CMD make test