aboutsummaryrefslogtreecommitdiff
path: root/gazelle/python/testdata/from_imports/import_nested_var
diff options
context:
space:
mode:
Diffstat (limited to 'gazelle/python/testdata/from_imports/import_nested_var')
-rw-r--r--gazelle/python/testdata/from_imports/import_nested_var/BUILD.in0
-rw-r--r--gazelle/python/testdata/from_imports/import_nested_var/BUILD.out9
-rw-r--r--gazelle/python/testdata/from_imports/import_nested_var/__init__.py16
3 files changed, 25 insertions, 0 deletions
diff --git a/gazelle/python/testdata/from_imports/import_nested_var/BUILD.in b/gazelle/python/testdata/from_imports/import_nested_var/BUILD.in
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/gazelle/python/testdata/from_imports/import_nested_var/BUILD.in
diff --git a/gazelle/python/testdata/from_imports/import_nested_var/BUILD.out b/gazelle/python/testdata/from_imports/import_nested_var/BUILD.out
new file mode 100644
index 0000000..8ee527e
--- /dev/null
+++ b/gazelle/python/testdata/from_imports/import_nested_var/BUILD.out
@@ -0,0 +1,9 @@
+load("@rules_python//python:defs.bzl", "py_library")
+
+py_library(
+ name = "import_nested_var",
+ srcs = ["__init__.py"],
+ imports = [".."],
+ visibility = ["//:__subpackages__"],
+ deps = ["//foo/bar:baz"],
+) \ No newline at end of file
diff --git a/gazelle/python/testdata/from_imports/import_nested_var/__init__.py b/gazelle/python/testdata/from_imports/import_nested_var/__init__.py
new file mode 100644
index 0000000..d0f51c4
--- /dev/null
+++ b/gazelle/python/testdata/from_imports/import_nested_var/__init__.py
@@ -0,0 +1,16 @@
+# Copyright 2023 The Bazel Authors. All rights reserved.
+#
+# 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.
+
+# baz is a variable in foo/bar/baz.py
+from foo.bar.baz import baz