Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
M
mysql
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ansible
mysql
Commits
78284188
Commit
78284188
authored
8 years ago
by
nimrod
Browse files
Options
Downloads
Patches
Plain Diff
- Start filling missing tests.
parent
8e43f5f3
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
tests/test_mysql.py
+15
-5
15 additions, 5 deletions
tests/test_mysql.py
with
15 additions
and
5 deletions
tests/test_mysql.py
+
15
−
5
View file @
78284188
...
...
@@ -13,11 +13,11 @@ def test_mysql_service(Service):
def
test_mysql_alias
(
File
):
p
ass
ass
ert
File
(
'
/etc/aliases
'
).
contains
(
'
mysql:
'
)
def
test_mysql_ssl_group
(
User
):
p
ass
ass
ert
'
ssl-cert
'
in
User
(
'
mysql
'
).
groups
def
test_mysql_admin_account
(
Command
,
Sudo
):
...
...
@@ -33,12 +33,22 @@ def test_mysql_backup_account(Command, Sudo):
def
test_mysql_backup_config
(
File
):
pass
backup_config
=
File
(
'
/etc/mysql/mysqldump.cnf
'
)
assert
backup_config
.
user
==
'
nobody
'
assert
backup_config
.
group
==
'
nogroup
'
assert
backup_config
.
mode
==
0o0400
def
test_mysql_backup_directory
(
File
):
pass
backup_dir
=
File
(
'
/var/backups/mysql
'
)
assert
backup_dir
.
is_directory
assert
backup_dir
.
user
==
'
nobody
'
assert
backup_dir
.
group
==
'
nogroup
'
assert
backup_dir
.
mode
==
0o0700
def
test_mysql_backup
(
Command
,
Sudo
):
pass
with
Sudo
(
'
nobody
'
):
mysql_backup
=
Command
(
'
mysql-backup
'
)
assert
mysql_backup
.
rc
==
0
assert
mysql_backup
.
stderr
==
''
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment