Skip to content

Commit

Permalink
YQ Connector: fix integration tests style (#640)
Browse files Browse the repository at this point in the history
  • Loading branch information
vitalyisaev2 authored Dec 22, 2023
1 parent 9d3feac commit 55c5812
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ def _large_table(self) -> Sequence[TestCase]:
test_cases = []
for data_source_kind in data_source_kinds:
tc = TestCase(
name=f'large_table',
name='large_table',
data_source_kind=data_source_kind,
data_in=data_in,
data_out_=data_in,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
from pathlib import Path
import subprocess
from typing import Final
import json

import jinja2

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
from os import environ
from dataclasses import dataclass
from typing import Optional, Sequence

Expand Down Expand Up @@ -46,7 +45,7 @@ def from_env(cls) -> 'Settings':
connector=cls.Connector(
grpc_host='localhost',
grpc_port=50051,
paging_bytes_per_page=4*1024*1024,
paging_bytes_per_page=4 * 1024 * 1024,
paging_prefetch_queue_capacity=2,
),
clickhouse=cls.ClickHouse(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import datetime
from typing import Sequence


def format_values_for_sql_insert(row: Sequence) -> str:
row_values_dump = []
for val in row:
Expand All @@ -17,6 +18,7 @@ def format_values_for_sql_insert(row: Sequence) -> str:
values = "(" + ", ".join(row_values_dump) + ")"
return values


def format_values_for_bulk_sql_insert(data_in: Sequence) -> str:
"""
This function helps to build multiline INSERTs, like this:
Expand Down
5 changes: 5 additions & 0 deletions ydb/library/yql/providers/generic/connector/tests/ya.make
Original file line number Diff line number Diff line change
Expand Up @@ -57,3 +57,8 @@ DEPENDS(
)

END()

RECURSE_FOR_TESTS(
test_cases
utils
)

0 comments on commit 55c5812

Please sign in to comment.