8000 Added minimal test for pg_wait_sampling · postgrespro/pg_wait_sampling@3fbf707 · GitHub
[go: up one dir, main page]

Skip to content

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

8000
Appearance settings

Commit 3fbf707

Browse files
committed
Added minimal test for pg_wait_sampling
1 parent aa4e0a9 commit 3fbf707

File tree

4 files changed

+31
-0
lines changed

4 files changed

+31
-0
lines changed

Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ OBJS = pg_wait_sampling.o collector.o
66
EXTENSION = pg_wait_sampling
77
DATA = pg_wait_sampling--1.0.sql
88

9+
REGRESS = load
10+
11+
EXTRA_REGRESS_OPTS=--temp-config=$(top_srcdir)/$(subdir)/conf.add
12+
913
ifdef USE_PGXS
1014
PG_CONFIG = pg_config
1115
PGXS := $(shell $(PG_CONFIG) --pgxs)

conf.add

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
shared_preload_libraries = 'pg_wait_sampling'

expected/load.out

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
< D57E code>1+
CREATE EXTENSION pg_wait_sampling;
2+
\d pg_wait_sampling_current
3+
View "public.pg_wait_sampling_current"
4+
Column | Type | Modifiers
5+
------------+---------+-----------
6+
pid | integer |
7+
event_type | text |
8+
event | text |
9+
10+
\d pg_wait_sampling_history
11+
View "public.pg_wait_sampling_history"
12+
Column | Type | Modifiers
13+
------------+--------------------------+-----------
14+
pid | integer |
15+
ts | timestamp with time zone |
16+
event_type | text |
17+
event | text |
18+
19+
DROP EXTENSION pg_wait_sampling;

sql/load.sql

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
CREATE EXTENSION pg_wait_sampling;
2+
3+
\d pg_wait_sampling_current
4+
5+
\d pg_wait_sampling_history
6+
7+
DROP EXTENSION pg_wait_sampling;

0 commit comments

Comments
 (0)
0