-
Notifications
You must be signed in to change notification settings - Fork 46
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
64 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
from astro.databases.duckdb import DuckdbDatabase | ||
|
||
|
||
def test_get_merge_initialization_query(): | ||
parameters = ("col_1", "col_2") | ||
|
||
sql = DuckdbDatabase.get_merge_initialization_query(parameters) | ||
assert sql == "CREATE UNIQUE INDEX merge_index ON {{table}}(col_1,col_2)" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,36 @@ | ||
line-length = 120 | ||
|
||
target-version = "py37" | ||
fix = true | ||
# Exclude a variety of commonly ignored directories. | ||
extend-exclude = ["__pycache__", "docs/source/conf.py"] | ||
|
||
[lint] | ||
extend-ignore = ["A002"] | ||
# Enable Pyflakes `E` and `F` codes by default. | ||
extend-select = [ | ||
"W", # pycodestyle warnings | ||
"I", # isort | ||
"C90", # Complexity | ||
# "B", # flake8-bugbear | ||
"C", # flake8-comprehensions | ||
# "ANN", # flake8-comprehensions | ||
"ISC", # flake8-implicit-str-concat | ||
"T10", # flake8-debugger | ||
"A", # flake8-builtins | ||
"UP", # pyupgrade | ||
"W", # pycodestyle warnings | ||
"I", # isort | ||
"C90", # Complexity | ||
# "B", # flake8-bugbear | ||
"C", # flake8-comprehensions | ||
# "ANN", # flake8-comprehensions | ||
"ISC", # flake8-implicit-str-concat | ||
"T10", # flake8-debugger | ||
"A", # flake8-builtins | ||
"UP", # pyupgrade | ||
] | ||
extend-ignore = ["A002"] | ||
|
||
# Exclude a variety of commonly ignored directories. | ||
extend-exclude = [ | ||
"__pycache__", | ||
"docs/source/conf.py", | ||
] | ||
|
||
target-version = "py37" | ||
fix = true | ||
|
||
[per-file-ignores] | ||
[lint.per-file-ignores] | ||
"python-sdk/src/astro/sql/__init__.py" = ["F401"] | ||
"python-sdk/src/astro/lineage/__init__.py" = ["F401"] | ||
"python-sdk/src/astro/sql/table.py" = ["F401"] | ||
|
||
|
||
[mccabe] | ||
[lint.mccabe] | ||
max-complexity = 6 | ||
|
||
[isort] | ||
[lint.isort] | ||
combine-as-imports = true | ||
known-first-party = ["astro", "tests"] |