Skip to content

Commit 5e398a3

Browse files
authored
Merge pull request #241 from supabase/ci/clickhouse-init-db
ci: remove clickhouse init db
2 parents 95239dd + 6967050 commit 5e398a3

File tree

4 files changed

+31
-11
lines changed

4 files changed

+31
-11
lines changed

Diff for: .github/workflows/test_wrappers.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,4 +55,4 @@ jobs:
5555
run: |
5656
cd wrappers && RUSTFLAGS="-D warnings" cargo clippy --all --tests --no-deps --features all_fdws,helloworld_fdw
5757
58-
- run: cd wrappers && cargo pgrx test --features all_fdws,pg15
58+
- run: cd wrappers && cargo pgrx test --features "all_fdws pg15"

Diff for: Cargo.lock

+25-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: wrappers/.ci/docker-compose.yaml

-2
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,6 @@ services:
2828
clickhouse:
2929
image: clickhouse/clickhouse-server
3030
container_name: clickhouse-wrapped
31-
environment:
32-
CLICKHOUSE_DB: supa
3331
ports:
3432
- "9000:9000" # native interface
3533
- "8123:8123" # http interface

Diff for: wrappers/src/fdw/clickhouse_fdw/tests.rs

+5-7
Original file line numberDiff line numberDiff line change
@@ -9,19 +9,17 @@ mod tests {
99
#[pg_test]
1010
fn clickhouse_smoketest() {
1111
Spi::connect(|mut c| {
12-
let clickhouse_pool = ch::Pool::new("tcp://default:@localhost:9000/supa");
12+
let clickhouse_pool = ch::Pool::new("tcp://default:@localhost:9000/default");
1313

1414
let rt = create_async_runtime().expect("failed to create runtime");
1515
let mut handle = rt
1616
.block_on(async { clickhouse_pool.get_handle().await })
1717
.expect("handle");
1818

1919
rt.block_on(async {
20+
handle.execute("DROP TABLE IF EXISTS test_table").await?;
2021
handle
21-
.execute("DROP TABLE IF EXISTS supa.test_table")
22-
.await?;
23-
handle
24-
.execute("CREATE TABLE supa.test_table (id INT, name TEXT) engine = Memory")
22+
.execute("CREATE TABLE test_table (id INT, name TEXT) engine = Memory")
2523
.await
2624
})
2725
.expect("test_table in ClickHouse");
@@ -37,7 +35,7 @@ mod tests {
3735
r#"CREATE SERVER my_clickhouse_server
3836
FOREIGN DATA WRAPPER clickhouse_wrapper
3937
OPTIONS (
40-
conn_string 'tcp://default:@localhost:9000/supa'
38+
conn_string 'tcp://default:@localhost:9000/default'
4139
)"#,
4240
None,
4341
None,
@@ -235,7 +233,7 @@ mod tests {
235233
let remote_value: String = rt
236234
.block_on(async {
237235
handle
238-
.query("SELECT name FROM supa.test_table ORDER BY name LIMIT 1")
236+
.query("SELECT name FROM test_table ORDER BY name LIMIT 1")
239237
.fetch_all()
240238
.await?
241239
.rows()

0 commit comments

Comments
 (0)