postgresql: move CI tests of *_tablespace, *_membership, *_idx to separate targets (#62575)
* postgresql: move CI tests of *_tablespace, *_membership, *_idx to separate targets * postgresql: move CI tests of *_tablespace, *_membership, *_idx to separate targets, change formatting
This commit is contained in:
parent
7047b66d34
commit
7b3d8431dd
16 changed files with 59 additions and 18 deletions
|
@ -2,9 +2,7 @@ destructive
|
|||
shippable/posix/group4
|
||||
postgresql_db
|
||||
postgresql_ext
|
||||
postgresql_idx
|
||||
postgresql_lang
|
||||
postgresql_membership
|
||||
postgresql_pg_hba
|
||||
postgresql_privs
|
||||
postgresql_publication
|
||||
|
@ -13,6 +11,5 @@ postgresql_sequence
|
|||
postgresql_set
|
||||
postgresql_slot
|
||||
postgresql_table
|
||||
postgresql_tablespace
|
||||
postgresql_user
|
||||
skip/osx
|
||||
|
|
|
@ -34,12 +34,6 @@
|
|||
# Verify different session_role scenarios
|
||||
- session_role.yml
|
||||
|
||||
# Test postgresql_idx module
|
||||
- postgresql_idx.yml
|
||||
|
||||
# Test postgresql_tablespace module
|
||||
- postgresql_tablespace.yml
|
||||
|
||||
# Test postgresql_db module, specific options
|
||||
- postgresql_db.yml
|
||||
|
||||
|
@ -49,9 +43,6 @@
|
|||
# Test postgresql_schema module
|
||||
- postgresql_schema.yml
|
||||
|
||||
# Test postgresql_membership module
|
||||
- postgresql_membership.yml
|
||||
|
||||
# Test postgresql_table module
|
||||
- postgresql_table.yml
|
||||
|
||||
|
|
|
@ -16,13 +16,37 @@
|
|||
|
||||
# Start tablespace option tests:
|
||||
block:
|
||||
# create tablespace for tests
|
||||
- name: postgresql_db_tablespace - Create tablespace
|
||||
<<: *task_parameters
|
||||
# Preparation for tests.
|
||||
- name: postgresql_db - drop dir for test tablespace
|
||||
become: yes
|
||||
become_user: root
|
||||
file:
|
||||
path: "{{ tblspc_location }}"
|
||||
state: absent
|
||||
ignore_errors: yes
|
||||
|
||||
- name: postgresql_db - disable selinux
|
||||
become: yes
|
||||
become_user: root
|
||||
shell: setenforce 0
|
||||
ignore_errors: yes
|
||||
|
||||
- name: postgresql_db - create dir for test tablespace
|
||||
become: yes
|
||||
become_user: root
|
||||
file:
|
||||
path: "{{ tblspc_location }}"
|
||||
state: directory
|
||||
owner: "{{ pg_user }}"
|
||||
group: "{{ pg_user }}"
|
||||
mode: 0700
|
||||
|
||||
# Create tablespace:
|
||||
- name: postgresql_db_ - create a new tablespace
|
||||
postgresql_tablespace:
|
||||
<<: *pg_parameters
|
||||
login_db: postgres
|
||||
name: "{{ db_tablespace }}"
|
||||
name: "{{ db_tablespace }}"
|
||||
location: "{{ tblspc_location }}"
|
||||
|
||||
# Check mode for DB creation with tablespace option:
|
||||
|
|
4
test/integration/targets/postgresql_idx/aliases
Normal file
4
test/integration/targets/postgresql_idx/aliases
Normal file
|
@ -0,0 +1,4 @@
|
|||
destructive
|
||||
shippable/posix/group4
|
||||
postgresql_idx
|
||||
skip/osx
|
3
test/integration/targets/postgresql_idx/meta/main.yml
Normal file
3
test/integration/targets/postgresql_idx/meta/main.yml
Normal file
|
@ -0,0 +1,3 @@
|
|||
---
|
||||
dependencies:
|
||||
- setup_postgresql_db
|
2
test/integration/targets/postgresql_idx/tasks/main.yml
Normal file
2
test/integration/targets/postgresql_idx/tasks/main.yml
Normal file
|
@ -0,0 +1,2 @@
|
|||
# Initial CI tests of postgresql_idx module
|
||||
- import_tasks: postgresql_idx_initial.yml
|
4
test/integration/targets/postgresql_membership/aliases
Normal file
4
test/integration/targets/postgresql_membership/aliases
Normal file
|
@ -0,0 +1,4 @@
|
|||
destructive
|
||||
shippable/posix/group4
|
||||
postgresql_membership
|
||||
skip/osx
|
|
@ -0,0 +1,3 @@
|
|||
---
|
||||
dependencies:
|
||||
- setup_postgresql_db
|
|
@ -0,0 +1,2 @@
|
|||
# Initial CI tests of postgresql_membership module
|
||||
- import_tasks: postgresql_membership_initial.yml
|
4
test/integration/targets/postgresql_tablespace/aliases
Normal file
4
test/integration/targets/postgresql_tablespace/aliases
Normal file
|
@ -0,0 +1,4 @@
|
|||
destructive
|
||||
shippable/posix/group4
|
||||
postgresql_tablespace
|
||||
skip/osx
|
|
@ -0,0 +1,2 @@
|
|||
---
|
||||
test_tablespace_path: "/ssd"
|
|
@ -0,0 +1,3 @@
|
|||
---
|
||||
dependencies:
|
||||
- setup_postgresql_db
|
|
@ -0,0 +1,2 @@
|
|||
# Initial CI tests of postgresql_tablespace module
|
||||
- import_tasks: postgresql_tablespace_initial.yml
|
|
@ -5,7 +5,7 @@
|
|||
- name: postgresql_tablespace - drop dir for test tablespace
|
||||
become: yes
|
||||
file:
|
||||
path: /ssd
|
||||
path: "{{ test_tablespace_path }}"
|
||||
state: absent
|
||||
ignore_errors: yes
|
||||
|
||||
|
@ -17,7 +17,7 @@
|
|||
- name: postgresql_tablespace - create dir for test tablespace
|
||||
become: yes
|
||||
file:
|
||||
path: /ssd
|
||||
path: "{{ test_tablespace_path }}"
|
||||
state: directory
|
||||
owner: "{{ pg_user }}"
|
||||
group: "{{ pg_user }}"
|
Loading…
Reference in a new issue