Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit0da2ee2

Browse files
author
v.shepard
committed
merge master
2 parents4f38bd5 +3cc9d67 commit0da2ee2

File tree

8 files changed

+29
-20
lines changed

8 files changed

+29
-20
lines changed

‎LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
testgres is released under the PostgreSQL License, a liberal Open Source license, similar to the BSD or MIT licenses.
22

3-
Copyright (c) 2016-2018, Postgres Professional
3+
Copyright (c) 2016-2023, Postgres Professional
44

55
Permission to use, copy, modify, and distribute this software and its documentation for any purpose, without fee, and without a written agreement is hereby granted, provided that the above copyright notice and this paragraph and the following two paragraphs appear in all copies.
66

‎docs/source/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
# -- Project information -----------------------------------------------------
2020

2121
project=u'testgres'
22-
copyright=u'2016-2022, Postgres Professional'
22+
copyright=u'2016-2023, Postgres Professional'
2323
author=u'Postgres Professional'
2424

2525
# The short X.Y version

‎publish_package.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
#!/usr/bin/env bash
22

3-
# Copyright (c) 2017-2022 Postgres Professional
4-
53
set -eux
64

75
# prepare environment
@@ -21,3 +19,4 @@ python3 setup.py sdist bdist_wheel
2119
twine upload dist/*
2220

2321
set +eux
22+

‎run_tests.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/usr/bin/env bash
22

3-
# Copyright (c) 2017-2022 Postgres Professional
3+
# Copyright (c) 2017-2023 Postgres Professional
44

55
set -eux
66

‎setup.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,13 @@
66
fromdistutils.coreimportsetup
77

88
# Basic dependencies
9-
install_requires= ["pg8000","port-for>=0.4","six>=1.9.0","psutil","fabric"]
9+
install_requires= [
10+
"pg8000",
11+
"port-for>=0.4",
12+
"six>=1.9.0",
13+
"psutil",
14+
"packaging",
15+
]
1016

1117
# Add compatibility enum class
1218
ifsys.version_info< (3,4):

‎testgres/node.py

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ class ProcessProxy(object):
116116
process: wrapped psutill.Process object
117117
ptype: instance of ProcessType
118118
"""
119+
119120
def__init__(self,process,ptype=None):
120121
self.process=process
121122
self.ptype=ptypeorProcessType.from_process(process)
@@ -710,12 +711,12 @@ def start(self, params=[], wait=True):
710711
returnself
711712

712713
_params= [
713-
get_bin_path("pg_ctl"),
714-
"-D",self.data_dir,
715-
"-l",self.pg_log_file,
716-
"-w"ifwaitelse'-W',# --wait or --no-wait
717-
"start"
718-
]+params# yapf: disable
714+
get_bin_path("pg_ctl"),
715+
"-D",self.data_dir,
716+
"-l",self.pg_log_file,
717+
"-w"ifwaitelse'-W',# --wait or --no-wait
718+
"start"
719+
]+params# yapf: disable
719720

720721
try:
721722
execute_utility(_params,self.utils_log_file)
@@ -765,7 +766,7 @@ def kill(self, someone=None):
765766
"""
766767
ifself.is_started:
767768
sig=signal.SIGKILLifos.name!='nt'elsesignal.SIGBREAK
768-
ifsomeone==None:
769+
ifsomeoneisNone:
769770
os.kill(self.pid,sig)
770771
else:
771772
os.kill(self.auxiliary_pids[someone][0],sig)
@@ -1509,10 +1510,10 @@ def querier():
15091510
returnsum
15101511

15111512
defpgbench_table_checksums(self,dbname="postgres",
1512-
pgbench_tables=('pgbench_branches',
1513-
'pgbench_tellers',
1514-
'pgbench_accounts',
1515-
'pgbench_history')
1513+
pgbench_tables=('pgbench_branches',
1514+
'pgbench_tellers',
1515+
'pgbench_accounts',
1516+
'pgbench_history')
15161517
):
15171518
return {(table,self.table_checksum(table,dbname))
15181519
fortableinpgbench_tables}

‎testgres/utils.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,10 @@
1212

1313
fromcontextlibimportcontextmanager
1414
frompackaging.versionimportVersion
15-
fromdistutils.spawnimportfind_executable
15+
try:
16+
fromshutilimportwhichasfind_executable
17+
exceptImportError:
18+
fromdistutils.spawnimportfind_executable
1619
fromsiximportiteritems
1720

1821
fromfabricimportConnection

‎tests/test_simple.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -171,8 +171,8 @@ def test_node_exit(self):
171171
deftest_double_start(self):
172172
withget_new_node().init().start()asnode:
173173
# can't start node more than once
174-
withself.assertRaises(StartNodeException):
175-
node.start()
174+
node.start()
175+
self.assertTrue(node.is_started)
176176

177177
deftest_uninitialized_start(self):
178178
withget_new_node()asnode:

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp