Integrate mg_client test with Apollo
Reviewers: teon.banek, buda, mculinovic Reviewed By: teon.banek Subscribers: pullbot Differential Revision: https://phabricator.memgraph.io/D1685
This commit is contained in:
parent
8c2e87b8a2
commit
7f2ad99ce7
9
tools/tests/apollo_runs.yaml
Normal file
9
tools/tests/apollo_runs.yaml
Normal file
@ -0,0 +1,9 @@
|
||||
- name: tools__test_mg_client
|
||||
commands: |
|
||||
./test_mg_client
|
||||
./test_mg_client --use-ssl
|
||||
infiles:
|
||||
- test_mg_client # test_mg_client script
|
||||
- client # test files
|
||||
- ../../build_release/memgraph # memgraph binary
|
||||
- ../../build_release/tools/src/mg_client # mg_client binary
|
@ -1,5 +1,5 @@
|
||||
+------------------------+
|
||||
+--------------------------+
|
||||
| n |
|
||||
+------------------------+
|
||||
+--------------------------+
|
||||
| (:Node {tmp: "\"\\;\\"}) |
|
||||
+------------------------+
|
||||
+--------------------------+
|
||||
|
@ -1,30 +1,30 @@
|
||||
+---------------------------------------------+
|
||||
+-----------------------------------------------+
|
||||
| n |
|
||||
+---------------------------------------------+
|
||||
+-----------------------------------------------+
|
||||
| (:Constantine {quote: "In hoc signo vinces"}) |
|
||||
+---------------------------------------------+
|
||||
+---------------------------------------------+
|
||||
+-----------------------------------------------+
|
||||
+-----------------------------------------------+
|
||||
| n |
|
||||
+---------------------------------------------+
|
||||
+-----------------------------------------------+
|
||||
| (:Constantine {quote: "In hoc signo vinces"}) |
|
||||
+---------------------------------------------+
|
||||
+-------------------------------------------------------+
|
||||
+-----------------------------------------------+
|
||||
+---------------------------------------------------------+
|
||||
| n |
|
||||
+-------------------------------------------------------+
|
||||
+---------------------------------------------------------+
|
||||
| (:Erdody {quote: "Regnum regno non praescribit leges"}) |
|
||||
+-------------------------------------------------------+
|
||||
+-------------------------------------------------------+
|
||||
+---------------------------------------------------------+
|
||||
+---------------------------------------------------------+
|
||||
| n |
|
||||
+-------------------------------------------------------+
|
||||
+---------------------------------------------------------+
|
||||
| (:Erdody {quote: "Regnum regno non praescribit leges"}) |
|
||||
+-------------------------------------------------------+
|
||||
+-----------------------------------+
|
||||
+---------------------------------------------------------+
|
||||
+-------------------------------------+
|
||||
| n |
|
||||
+-----------------------------------+
|
||||
+-------------------------------------+
|
||||
| (:Caesar {quote: "Alea iacta est"}) |
|
||||
+-----------------------------------+
|
||||
+-----------------------------------+
|
||||
+-------------------------------------+
|
||||
+-------------------------------------+
|
||||
| n |
|
||||
+-----------------------------------+
|
||||
+-------------------------------------+
|
||||
| (:Caesar {quote: "Alea iacta est"}) |
|
||||
+-----------------------------------+
|
||||
+-------------------------------------+
|
||||
|
@ -1,5 +1,5 @@
|
||||
+---------+---------+---------+
|
||||
+-----------+-----------+-----------+
|
||||
| n | e | m |
|
||||
+---------+---------+---------+
|
||||
+-----------+-----------+-----------+
|
||||
| (:Node) | [Edge] | (:Vertex) |
|
||||
+---------+---------+---------+
|
||||
+-----------+-----------+-----------+
|
||||
|
@ -1,15 +1,15 @@
|
||||
+-------+
|
||||
+---------+
|
||||
| n |
|
||||
+-------+
|
||||
+---------+
|
||||
| (:Node) |
|
||||
+-------+
|
||||
+---------+
|
||||
+-----------+
|
||||
| n |
|
||||
+---------+
|
||||
+-----------+
|
||||
| (:Vertex) |
|
||||
+---------+
|
||||
+---------+
|
||||
+-----------+
|
||||
+-----------+
|
||||
| n |
|
||||
+---------+
|
||||
+-----------+
|
||||
| (:Vertex) |
|
||||
+---------+
|
||||
+-----------+
|
||||
|
@ -1,20 +1,20 @@
|
||||
+-------+
|
||||
+---------+
|
||||
| n |
|
||||
+-------+
|
||||
+---------+
|
||||
| (:Node) |
|
||||
+-------+
|
||||
+-------+
|
||||
+---------+
|
||||
+---------+
|
||||
| n |
|
||||
+-------+
|
||||
+---------+
|
||||
| (:Node) |
|
||||
+-------+
|
||||
+---------+
|
||||
+-----------+
|
||||
| n |
|
||||
+---------+
|
||||
+-----------+
|
||||
| (:Vertex) |
|
||||
+---------+
|
||||
+---------+
|
||||
+-----------+
|
||||
+-----------+
|
||||
| n |
|
||||
+---------+
|
||||
+-----------+
|
||||
| (:Vertex) |
|
||||
+---------+
|
||||
+-----------+
|
||||
|
@ -1,25 +1,25 @@
|
||||
+---------------------------------------+
|
||||
+-----------------------------------------+
|
||||
| n |
|
||||
+---------------------------------------+
|
||||
+-----------------------------------------+
|
||||
| (:Ciceron {quote: "o tempora o mores"}) |
|
||||
+---------------------------------------+
|
||||
+----------------------------------------+
|
||||
+-----------------------------------------+
|
||||
+------------------------------------------+
|
||||
| n |
|
||||
+----------------------------------------+
|
||||
+------------------------------------------+
|
||||
| (:Ciceron {quote: "o tempora o mores!"}) |
|
||||
+----------------------------------------+
|
||||
+-------------------------------------------+
|
||||
+------------------------------------------+
|
||||
+---------------------------------------------+
|
||||
| n |
|
||||
+-------------------------------------------+
|
||||
+---------------------------------------------+
|
||||
| (:Ciceron {quote: "o tempora \'o mores\'"}) |
|
||||
+-------------------------------------------+
|
||||
+-------------------------------------------+
|
||||
+---------------------------------------------+
|
||||
+---------------------------------------------+
|
||||
| n |
|
||||
+-------------------------------------------+
|
||||
+---------------------------------------------+
|
||||
| (:Ciceron {quote: "o tempora \"o mores\""}) |
|
||||
+-------------------------------------------+
|
||||
+-------------------------------------------+
|
||||
+---------------------------------------------+
|
||||
+---------------------------------------------+
|
||||
| n |
|
||||
+-------------------------------------------+
|
||||
+---------------------------------------------+
|
||||
| (:Ciceron {quote: "o tempora \"o mores\""}) |
|
||||
+-------------------------------------------+
|
||||
+---------------------------------------------+
|
||||
|
@ -1,30 +1,30 @@
|
||||
+-------------------------------------+
|
||||
+---------------------------------------+
|
||||
| n |
|
||||
+-------------------------------------+
|
||||
+---------------------------------------+
|
||||
| (:Ovid {quote: "Exitus Acta Probat"}) |
|
||||
+-------------------------------------+
|
||||
+-------------------------------------+
|
||||
+---------------------------------------+
|
||||
+---------------------------------------+
|
||||
| n |
|
||||
+-------------------------------------+
|
||||
+---------------------------------------+
|
||||
| (:Ovid {quote: "Exitus Acta Probat"}) |
|
||||
+-------------------------------------+
|
||||
+-------------------------------------+
|
||||
+---------------------------------------+
|
||||
+---------------------------------------+
|
||||
| n |
|
||||
+-------------------------------------+
|
||||
+---------------------------------------+
|
||||
| (:Ovid {quote: "Exitus Acta Probat"}) |
|
||||
+-------------------------------------+
|
||||
+----------------------------+
|
||||
+---------------------------------------+
|
||||
+------------------------------+
|
||||
| n |
|
||||
+----------------------------+
|
||||
+------------------------------+
|
||||
| (:Bible {quote: "Fiat Lux"}) |
|
||||
+----------------------------+
|
||||
+-------------------------------------+
|
||||
+------------------------------+
|
||||
+---------------------------------------+
|
||||
| n |
|
||||
+-------------------------------------+
|
||||
+---------------------------------------+
|
||||
| (:Plinius {quote: "In vino veritas"}) |
|
||||
+-------------------------------------+
|
||||
+-------------------------------------+
|
||||
+---------------------------------------+
|
||||
+---------------------------------------+
|
||||
| n |
|
||||
+-------------------------------------+
|
||||
+---------------------------------------+
|
||||
| (:Plinius {quote: "In vino veritas"}) |
|
||||
+-------------------------------------+
|
||||
+---------------------------------------+
|
||||
|
@ -54,12 +54,25 @@ if [ ! -d $input_dir ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Check and generate SSL certificates
|
||||
use_ssl=false
|
||||
key_file=""
|
||||
cert_file=""
|
||||
if [ "$1" == "--use-ssl" ]; then
|
||||
use_ssl=true
|
||||
key_file=".key.pem"
|
||||
cert_file=".cert.pem"
|
||||
openssl req -new -newkey rsa:4096 -days 365 -nodes -x509 \
|
||||
-subj "/C=HR/ST=Zagreb/L=Zagreb/O=Memgraph/CN=db.memgraph.com" \
|
||||
-keyout $key_file -out $cert_file || exit 1
|
||||
fi
|
||||
|
||||
|
||||
## Startup
|
||||
|
||||
# Start the memgraph process and wait for it to start.
|
||||
echo_info "Starting memgraph"
|
||||
$memgraph_dir/memgraph &> /dev/null &
|
||||
$memgraph_dir/memgraph --cert-file=$cert_file --key-file=$key_file &
|
||||
pid=$!
|
||||
wait_for_server 7687
|
||||
echo_success "Started memgraph"
|
||||
@ -70,7 +83,7 @@ echo_success "Started memgraph"
|
||||
echo_info "Running tests"
|
||||
echo # Blank line
|
||||
|
||||
client_flags="--use-ssl=false"
|
||||
client_flags="--use-ssl=$use_ssl"
|
||||
test_code=0
|
||||
for output_dir in $tests_dir/output_*; do
|
||||
for filename in $input_dir/*; do
|
||||
|
Loading…
Reference in New Issue
Block a user