blob: 83d994e7c65af31496b7fdae1b395337e73f2fa1 [file] [log] [blame]
Chris McDonalde69db662018-11-15 12:50:18 -07001# -*- coding: utf-8 -*-
2# Copyright 2018 The Chromium OS Authors. All rights reserved.
3# Use of this source code is governed by a BSD-style license that can be
4# found in the LICENSE file.
5
6"""Unit tests for cros_run_unit_tests.py."""
7
8from __future__ import print_function
9
Mike Frysinger6a2b0f22020-02-20 13:34:07 -050010import sys
11
Chris McDonalde69db662018-11-15 12:50:18 -070012from chromite.lib import cros_test_lib
13from chromite.scripts import cros_run_unit_tests
14
Greg Edelstona4c9b3b2020-01-07 17:51:13 -070015pytestmark = cros_test_lib.pytestmark_inside_only
16
Chris McDonalde69db662018-11-15 12:50:18 -070017
Mike Frysinger6a2b0f22020-02-20 13:34:07 -050018assert sys.version_info >= (3, 6), 'This module requires Python 3.6+'
19
20
Chris McDonalde69db662018-11-15 12:50:18 -070021class DetermineBoardPackagesTest(cros_test_lib.TestCase):
22 """Tests that package determination returns a non-empty set"""
23
Chris McDonalde69db662018-11-15 12:50:18 -070024 def testNonEmptyPackageSet(self):
25 """Asserts that the deps of a known package are non-empty"""
26 self.assertTrue(cros_run_unit_tests.determine_board_packages(
27 '/', ('virtual/implicit-system',)))