-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathMakefile
More file actions
166 lines (130 loc) · 5.18 KB
/
Makefile
File metadata and controls
166 lines (130 loc) · 5.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# ============================================================================
# Glue
# ============================================================================
.PHONY: lint-glue
lint-glue:
uv run ruff check src/lance_namespace_impls/glue.py tests/test_glue.py tests/test_glue_integration.py
uv run ruff format --check src/lance_namespace_impls/glue.py tests/test_glue.py tests/test_glue_integration.py
.PHONY: install-glue
install-glue:
uv sync --extra glue --extra dev
.PHONY: test-glue
test-glue:
uv run pytest tests/test_glue.py
# ============================================================================
# Hive2
# ============================================================================
.PHONY: lint-hive
lint-hive:
uv run ruff check src/lance_namespace_impls/hive2.py src/lance_namespace_impls/hive3.py src/lance_namespace_impls/hive2_page_util.py tests/test_hive2.py tests/test_hive3.py tests/test_hive2_page_util.py tests/test_hive2_integration.py tests/test_hive3_integration.py
uv run ruff format --check src/lance_namespace_impls/hive2.py src/lance_namespace_impls/hive3.py src/lance_namespace_impls/hive2_page_util.py tests/test_hive2.py tests/test_hive3.py tests/test_hive2_page_util.py tests/test_hive2_integration.py tests/test_hive3_integration.py
.PHONY: install-hive
install-hive:
uv sync --extra hive2 --extra hive3 --extra dev
.PHONY: test-hive
test-hive:
uv run pytest tests/test_hive2.py tests/test_hive3.py tests/test_hive2_page_util.py
# ============================================================================
# Unity
# ============================================================================
.PHONY: lint-unity
lint-unity:
uv run ruff check src/lance_namespace_impls/unity.py tests/test_unity.py tests/test_unity_integration.py
uv run ruff format --check src/lance_namespace_impls/unity.py tests/test_unity.py tests/test_unity_integration.py
.PHONY: install-unity
install-unity:
uv sync --extra unity --extra dev
.PHONY: test-unity
test-unity:
uv run pytest tests/test_unity.py
# ============================================================================
# Iceberg
# ============================================================================
.PHONY: lint-iceberg
lint-iceberg:
uv run ruff check src/lance_namespace_impls/iceberg.py tests/test_iceberg.py tests/test_iceberg_integration.py
uv run ruff format --check src/lance_namespace_impls/iceberg.py tests/test_iceberg.py tests/test_iceberg_integration.py
.PHONY: install-iceberg
install-iceberg:
uv sync --extra iceberg --extra dev
.PHONY: test-iceberg
test-iceberg:
uv run pytest tests/test_iceberg.py
# ============================================================================
# Polaris
# ============================================================================
.PHONY: lint-polaris
lint-polaris:
uv run ruff check src/lance_namespace_impls/polaris.py tests/test_polaris.py tests/test_polaris_integration.py
uv run ruff format --check src/lance_namespace_impls/polaris.py tests/test_polaris.py tests/test_polaris_integration.py
.PHONY: install-polaris
install-polaris:
uv sync --extra polaris --extra dev
.PHONY: test-polaris
test-polaris:
uv run pytest tests/test_polaris.py
# ============================================================================
# All
# ============================================================================
.PHONY: lint
lint:
uv run ruff check .
uv run ruff format --check .
.PHONY: install
install:
uv sync --extra all --extra dev
.PHONY: test
test:
uv run pytest tests/
.PHONY: clean
clean:
rm -rf dist/
rm -rf build/
rm -rf *.egg-info
rm -rf src/*.egg-info
find . -type d -name __pycache__ -exec rm -rf {} +
find . -type f -name "*.pyc" -delete
.PHONY: build
build:
uv build
.PHONY: publish
publish:
uv build
# ============================================================================
# Integration tests
# ============================================================================
.PHONY: integ-test
integ-test:
uv run pytest tests/ -m integration
.PHONY: integ-test-hive
integ-test-hive:
uv run pytest tests/test_hive2_integration.py tests/test_hive3_integration.py -v
.PHONY: integ-test-hive2
integ-test-hive2:
uv run pytest tests/test_hive2_integration.py -v
.PHONY: integ-test-hive3
integ-test-hive3:
uv run pytest tests/test_hive3_integration.py -v
.PHONY: integ-test-polaris
integ-test-polaris:
uv run pytest tests/test_polaris_integration.py -v
.PHONY: integ-test-unity
integ-test-unity:
uv run pytest tests/test_unity_integration.py -v
.PHONY: integ-test-iceberg
integ-test-iceberg:
uv run pytest tests/test_iceberg_integration.py -v
.PHONY: integ-test-glue
integ-test-glue:
uv run pytest tests/test_glue_integration.py -v