MCPcopy Create free account
hub / github.com/CrunchyData/postgres-operator / TestWALDirectory

Function TestWALDirectory

internal/postgres/config_test.go:132–143  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

130}
131
132func TestWALDirectory(t *testing.T) {
133 cluster := new(v1beta1.PostgresCluster)
134 cluster.Spec.PostgresVersion = 13
135
136 // without WAL volume
137 instance := new(v1beta1.PostgresInstanceSetSpec)
138 assert.Equal(t, WALDirectory(cluster, instance), "/pgdata/pg13_wal")
139
140 // with WAL volume
141 instance.WALVolumeClaimSpec = new(v1beta1.VolumeClaimSpecWithAutoGrow)
142 assert.Equal(t, WALDirectory(cluster, instance), "/pgwal/pg13_wal")
143}
144
145func TestBashHalt(t *testing.T) {
146 t.Run("NoPipeline", func(t *testing.T) {

Callers

nothing calls this directly

Calls 2

WALDirectoryFunction · 0.85
EqualMethod · 0.45

Tested by

no test coverage detected