Move lcm certificate to lcm folder in OSM helm chart
[osm/devops.git] / installers / test_track.sh
1 #!/bin/bash
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 # http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14 #
15
16 source ../common/track
17 source ../common/logging
18
19 RELEASE="test_track"
20 OSM_DOCKER_TAG=latest
21 OSM_TRACK_INSTALLATION_ID="$(date +%s)-$(head /dev/urandom | tr -dc A-Za-z0-9 | head -c 16)"
22
23 echo "Next track call should fail"
24 echo "track"
25 track
26 echo
27 echo "Next, several track calls are done with different args"
28 echo "track test-event"
29 track test-event
30 sleep 1
31 echo "track test-event release $RELEASE"
32 track test-event release $RELEASE
33 sleep 1
34 echo "track test-event docker_tag $OSM_DOCKER_TAG none none"
35 track test-event docker_tag $OSM_DOCKER_TAG none none
36 sleep 1
37 echo "track test-event release $RELEASE none none docker_tag $OSM_DOCKER_TAG none none"
38 track test-event release $RELEASE none none docker_tag $OSM_DOCKER_TAG none none
39 sleep 1
40 echo 'track test-event my-op my-value "My comment" none'
41 track test-event my-op my-value "My comment" none
42 sleep 1
43 echo 'track test-event my-op my-value "My comment" "tag1,tag2"'
44 track test-event my-op my-value "My comment" "tag1,tag2"
45 sleep 1
46 echo 'track test-event op1 value1 "My comment1 on test event" none op2 value2 "My comment2 on test event" none'
47 track test-event op1 value1 "My comment1 on test event" none op2 value2 "My comment2 on test event" none
48 sleep 1
49 echo
50 echo "Next track call will be done from function FATAL_TRACK"
51 echo 'FATAL_TRACK test-event "Fatal error during execution"'
52 FATAL_TRACK test-event "Fatal error during execution"
53