-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathphp-structure-test.yaml
106 lines (91 loc) · 2.66 KB
/
php-structure-test.yaml
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
103
104
105
106
schemaVersion: '2.0.0'
fileExistenceTests:
- name: "PHP binary is present"
path: "/usr/local/bin/php"
shouldExist: true
- name: "Composer is present"
path: "/usr/local/bin/composer"
shouldExist: true
- name: "WP-CLI is present"
path: "/usr/local/bin/wp"
shouldExist: true
- name: "Docker entrypoint is present"
path: "/usr/local/bin/docker-entrypoint.sh"
shouldExist: true
- name: "MSMTP is present"
path: "/usr/bin/msmtp"
shouldExist: true
- name: "Git is present"
path: "/usr/bin/git"
shouldExist: true
- name: "MySQL client is present"
path: "/usr/bin/mysql"
shouldExist: true
- name: "Unzip is present"
path: "/usr/bin/unzip"
shouldExist: true
- name: "ImageMagick is present"
path: "/usr/bin/convert"
shouldExist: true
commandTests:
- name: "PHP is installed"
command: "php"
args: ["-v"]
expectedOutput: ["PHP"]
- name: "Composer is installed"
command: "composer"
args: ["--version"]
expectedOutput: ["Composer"]
- name: "WP-CLI is installed"
command: "wp"
args: ["--version"]
expectedOutput: ["WP-CLI"]
- name: "PHP extensions are installed"
command: "php"
args: ["-m"]
expectedOutput: [
"json", "mysqli", "curl", "dom", "exif", "fileinfo", "hash", "igbinary",
"imagick", "intl", "mbstring", "openssl", "pcre", "xml", "zip", "apcu",
"OPcache", "redis", "bcmath", "filter", "iconv", "shmop",
"SimpleXML", "sodium", "xmlreader", "zlib", "ssh2", "ftp", "sockets"
]
- name: "Imagick PHP extension is enabled"
command: "php"
args: ["-m"]
expectedOutput: ["imagick"]
- name: "Redis PHP extension is enabled"
command: "php"
args: ["-m"]
expectedOutput: ["redis"]
- name: "Relay PHP extension is enabled"
command: "php"
args: ["-m"]
expectedOutput: ["relay"]
- name: "APCu PHP extension is enabled"
command: "php"
args: ["-m"]
expectedOutput: ["apcu"]
- name: "WP-CLI doctor package is installed"
command: "wp"
args: ["package", "list"]
expectedOutput: ["doctor"]
- name: "Git is installed"
command: "git"
args: ["--version"]
expectedOutput: ["git version"]
# - name: "MySQL client is installed"
# command: "bash"
# args: ["-c", "mysql --version 2>/dev/null"]
# expectedOutput: ["mysql from", "client"]
- name: "MariaDB client is installed"
command: "mariadb"
args: ["--version"]
expectedOutput: ["mariadb"]
- name: "Unzip is installed"
command: "unzip"
args: ["-v"]
expectedOutput: ["UnZip"]
- name: "ImageMagick is installed"
command: "convert"
args: ["-version"]
expectedOutput: ["ImageMagick"]