Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 0 additions & 13 deletions test/local/BUILD

This file was deleted.

7 changes: 0 additions & 7 deletions test/local/local_lib_import_test.py

This file was deleted.

8 changes: 0 additions & 8 deletions test/local/local_lib_no_import_test.py

This file was deleted.

13 changes: 13 additions & 0 deletions test/site/BUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
subinclude("//build_defs:python")

python_test(
name = "site_test",
srcs = ["site_test.py"],
site = True,
)

python_test(
name = "no_site_test",
srcs = ["no_site_test.py"],
site = False,
)
9 changes: 9 additions & 0 deletions test/site/no_site_test.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import sys
import unittest


class NoSiteTest(unittest.TestCase):

def test_no_site_flag_passed(self):
"""Ensures that the Python interpreter was invoked with the -S option."""
self.assertTrue(sys.flags.no_site)
9 changes: 9 additions & 0 deletions test/site/site_test.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import sys
import unittest


class SiteTest(unittest.TestCase):

def test_no_site_flag_not_passed(self):
"""Ensures that the Python interpreter was *not* invoked with the -S option."""
self.assertFalse(sys.flags.no_site)