summaryrefslogtreecommitdiffstats
path: root/packages/arquillian-unit-tests/src/test/resources/arquillian.xml
blob: 7606450809575fc2200a0e931f6cbe81f09e849c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
<arquillian xmlns="http://jboss.org/schema/arquillian"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="
        http://jboss.org/schema/arquillian
        http://jboss.org/schema/arquillian/arquillian_1_0.xsd">

    <defaultProtocol type="Servlet 3.0" />

	<extension qualifier="cube">
	  <property name="connectionMode">STARTANDSTOP</property>
	</extension>

    <extension qualifier="docker">

      <property name="serverVersion">1.23</property>

      <property name="serverUri">${docker.url}</property>
      <property name="definitionFormat">CUBE</property>
      <property name="dockerContainers">
         mso:
           image: ecomp/mso-arquillian:${images.version}
           beforeStop:
            - copy:
                   from: /opt/jboss/standalone/log/
                   to: ${target.folder}/mso-automated-tests/jboss-logs
            - copy:
                   from: /var/log/ecomp/MSO
                   to: ${target.folder}/mso-automated-tests/mso-logs
            - copy:
                   from: /tmp/mso-log-checker.log
                   to: ${target.folder}/mso-automated-tests/
           hostName: mso
           await:
              strategy: http
              match: 'regexp:(.*)Welcome to WildFly 10(.*)'
              responseCode: 200
              url: http://dockerHost:18080
              sleepPollingTime: 30 s
              iterations: 20
           portBindings: [18080->8080/tcp, 9990/tcp, 9999/tcp]
           volumes: [/shared]
           binds:
            - ${target.folder}/test-classes/docker/mso:/shared
           links:
             - mariadb:mariadb
             - jacoco-shared:jacoco-shared
         jacoco-shared:
            image: ecomp/jacoco:1.0
            beforeStop:
             - copy:
                   from: /shared/jacoco-it.exec
                   to: ${target.folder}/mso-automated-tests/
            hostName: jacoco
            volumes: [/shared]
            binds:
             - ${target.folder}/test-classes/docker/mso:/shared:ro
         mariadb:
            image: mariadb:10.1.11
            beforeStop:
                - log:
                   to: ${target.folder}/mso-automated-tests/db/mariadb.log
                   follow: false
                   stdout: true
                   stderr: true
                   timestamps: true
            exposedPorts: [3306/tcp]
            await:
             strategy: polling
             ports: [3306]
             sleepPollingTime: 5 s
             iterations: 24
            env: [MYSQL_ROOT_PASSWORD=Etoile19_]
            portBindings: [3306/tcp]
            hostName: mariadb
            volumes: [/etc/mysql/conf.d,/docker-entrypoint-initdb.d]
            binds:
             - ${target.folder}/test-classes/docker/mariadb/conf1:/etc/mysql/conf.d:ro
             - ${target.folder}/../../root-pack-extras/config-resources/mariadb:/docker-entrypoint-initdb.d:ro

        </property>
        <property name="shouldAllowToConnectToRunningContainers">false</property>
        <property name="clean">true</property>
        <property name="removeVolumes">true</property>
        <property name="autoStartContainers">mso</property>
    </extension>


    <container qualifier="jboss-as" default="true">
        <configuration>
            <property name="managementAddress">${docker.hostname}</property>
            <property name="managementPort">9990</property>
            <property name="username">admin</property>
            <property name="password">Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U</property>
        </configuration>
        <protocol type="Servlet 3.0">
        	<property name="host">${docker.hostname}</property>
        	<property name="port">18080</property>
    	</protocol>
    </container>


</arquillian>