Skip to content

Commit 6ad811d

Browse files
author
v.shepard
committed
testgres from PBCKP-152-multihost
Merge branch 'master' of https://github.com/postgrespro/testgres into PBCKP-152-multihost
2 parents 0da2ee2 + 94f9b35 commit 6ad811d

File tree

6 files changed

+7
-12
lines changed

6 files changed

+7
-12
lines changed

testgres/api.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@
3030
PostgresNode(name='...', port=..., base_dir='...')
3131
[(3,)]
3232
"""
33-
from defaults import default_username
3433
from .node import PostgresNode
3534

3635

testgres/backup.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,7 @@
44

55
from shutil import rmtree, copytree
66
from six import raise_from
7-
from tempfile import mkdtemp
87

9-
from os_ops import OsOperations
108
from .enums import XLogMethod
119

1210
from .consts import \

testgres/cache.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
11
# coding: utf-8
22

3-
import io
43
import os
54

6-
from shutil import copytree
75
from six import raise_from
86

9-
from os_ops import OsOperations
7+
from .os_ops import OsOperations
108
from .config import testgres_config
119

1210
from .consts import XLOG_CONTROL_FILE

testgres/connection.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
# coding: utf-8
2-
from os_ops import OsOperations
32

43
# we support both pg8000 and psycopg2
54
try:

testgres/node.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
import subprocess
1313
import time
1414

15-
from os_ops import OsOperations
1615

1716
try:
1817
from collections.abc import Iterable
@@ -102,6 +101,7 @@
102101
clean_on_error
103102

104103
from .backup import NodeBackup
104+
from .os_ops import OsOperations
105105

106106
InternalError = pglib.InternalError
107107
ProgrammingError = pglib.ProgrammingError
@@ -1606,8 +1606,10 @@ def make_simple(
16061606
set_replication=False,
16071607
ptrack_enable=False,
16081608
initdb_params=[],
1609-
pg_options={}):
1610-
1609+
pg_options={},
1610+
checksum=True):
1611+
if checksum and '--data-checksums' not in initdb_params:
1612+
initdb_params.append('--data-checksums')
16111613
node = self.make_empty(base_dir)
16121614
node.init(
16131615
initdb_params=initdb_params, allow_streaming=set_replication)

testgres/os_ops.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import base64
21
import getpass
32
import os
43
import shutil
@@ -15,7 +14,7 @@
1514
except ImportError:
1615
raise ImportError("You must have psycopg2 or pg8000 modules installed")
1716

18-
from defaults import default_username
17+
from testgres.defaults import default_username
1918
from testgres.logger import log
2019

2120
import paramiko

0 commit comments

Comments
 (0)