SuiteModuleLoader
public
class
SuiteModuleLoader
extends Object
| java.lang.Object | |
| ↳ | com.android.tradefed.testtype.suite.SuiteModuleLoader |
מאחזר את ההגדרות של מודול בדיקת התאימות מהמאגר. TODO: Add the expansion of suite when loading a module.
סיכום
כיתות מוטמעות | |
|---|---|
class |
SuiteModuleLoader.ConfigFilter
פקודת |
ערכים קבועים | |
|---|---|
String |
CONFIG_EXT
|
constructors ציבוריים | |
|---|---|
SuiteModuleLoader(Map<String, LinkedHashSet<SuiteTestFilter>> includeFilters, Map<String, LinkedHashSet<SuiteTestFilter>> excludeFilters, List<String> testArgs, List<String> moduleArgs)
Ctor for the SuiteModuleLoader. |
|
methods ציבוריים | |
|---|---|
static
void
|
addFilters(Set<String> stringFilters, Map<String, LinkedHashSet<SuiteTestFilter>> filters, Set<IAbi> abis, Set<DeviceFoldableState> foldableStates)
שיטת עזר שמאפשרת לנתח וליצור מבנה עם מסנני האפשרויות. |
void
|
addFiltersToTest(IRemoteTest test, IAbi abi, String moduleId, Map<String, LinkedHashSet<SuiteTestFilter>> includeFilters, Map<String, LinkedHashSet<SuiteTestFilter>> excludeFilters)
מעבירים את המסננים אל |
static
Set<File>
|
getModuleNamesMatching(File directory, String suitePrefix, String pattern)
|
LinkedHashMap<String, IConfiguration>
|
loadConfigsFromDirectory(List<File> testsDirs, Set<IAbi> abis, String suitePrefix, String suiteTag, List<String> patterns)
טעינה ראשית של הגדרות, בדיקה בתיקייה |
LinkedHashMap<String, IConfiguration>
|
loadConfigsFromJars(Set<IAbi> abis, String suitePrefix, String suiteTag)
טעינה ראשית של ההגדרות, בדיקת המשאבים בנתיב המחלקה. |
LinkedHashMap<String, IConfiguration>
|
loadConfigsFromSpecifiedPaths(List<File> listConfigFiles, Set<IAbi> abis, String suiteTag)
טעינה ראשית של ההגדרות, בדיקה של הקבצים שצוינו |
LinkedHashMap<String, IConfiguration>
|
loadTfConfigsFromSpecifiedPaths(List<String> configs, Set<IAbi> abis, String suiteTag)
טעינה ראשית של ההגדרות, בדיקה של המשאבים שצוינו בנתיב המחלקה. |
final
void
|
setExcludedModuleParameters(Set<ModuleParameters> excludedParams)
מגדיר את קבוצת |
final
void
|
setFoldableStates(Set<DeviceFoldableState> foldableStates)
מגדירה את קבוצת ה- |
final
void
|
setIgnoreNonPreloadedMainlineModule(boolean ignore)
ההגדרה הזו קובעת אם להתעלם מהתקנת המודול אם הוא לא נטען מראש. |
final
void
|
setInvocationContext(IInvocationContext context)
|
final
void
|
setLoadConfigsWithIncludeFilters(boolean allowed)
הגדרת האפשרות הזו קובעת אם להטעין את הגדרות הבדיקה על סמך מסנן ההכללה שצוין. |
final
void
|
setMainlineParameterizedModules(boolean allowed)
ההגדרה הזו קובעת אם לאפשר מודולים ראשיים עם פרמטרים. |
final
void
|
setModuleParameter(ModuleParameters param)
מגדיר את סוג |
final
void
|
setOptimizeMainlineTest(boolean allowed)
הגדרה שקובעת אם לבצע אופטימיזציה של בדיקת ה-mainline. |
final
void
|
setOptionalParameterizedModules(boolean allowed)
ההגדרה הזו קובעת אם לאפשר מודולים אופציונליים עם פרמטרים. |
final
void
|
setParameterizedModules(boolean allowed)
ההגדרה הזו קובעת אם לאפשר מודולים עם פרמטרים. |
final
void
|
setUseIncludeFilterOrder(boolean useIncludeFilterOrder)
קובעת אם לארגן את ביצוע הבדיקה לפי הסדר שצוין במסנן include. |
ערכים קבועים
CONFIG_EXT
public static final String CONFIG_EXT
ערך קבוע: ".config"
constructors ציבוריים
SuiteModuleLoader
public SuiteModuleLoader (Map<String, LinkedHashSet<SuiteTestFilter>> includeFilters, Map<String, LinkedHashSet<SuiteTestFilter>> excludeFilters, List<String> testArgs, List<String> moduleArgs)
Ctor for the SuiteModuleLoader.
| פרמטרים | |
|---|---|
includeFilters |
Map: מסנני הכללה מעוצבים ומנותחים. |
excludeFilters |
Map: מסנני ההחרגה המעוצבים והמנותחים. |
testArgs |
List: רשימת הארגומנטים של הבדיקה (IRemoteTest). |
moduleArgs |
List: רשימת הארגומנטים של המודול. |
methods ציבוריים
addFilters
public static void addFilters (Set<String> stringFilters,
Map<String, LinkedHashSet<SuiteTestFilter>> filters,
Set<IAbi> abis,
Set<DeviceFoldableState> foldableStates)שיטת עזר שמאפשרת לנתח וליצור מבנה עם מסנני האפשרויות.
| פרמטרים | |
|---|---|
stringFilters |
Set: הפורמט של המסננים של האפשרויות המקוריות. |
filters |
Map: המסננים שנותחו מהפורמט של המחרוזת. |
abis |
Set: ה-Abi שרוצים להשתמש בו לסינון. |
foldableStates |
Set |
addFiltersToTest
public void addFiltersToTest (IRemoteTest test, IAbi abi, String moduleId, Map<String, LinkedHashSet<SuiteTestFilter>> includeFilters, Map<String, LinkedHashSet<SuiteTestFilter>> excludeFilters)
מעבירים את המסננים אל IRemoteTest. ההתנהגות בברירת מחדל היא להתעלם אם הממשק IRemoteTest
לא מיישם את ITestFileFilterReceiver. אפשר לשנות את ההגדרה הזו כדי ליצור התנהגות מגבילה יותר.
| פרמטרים | |
|---|---|
test |
IRemoteTest: IRemoteTest שנבדק. |
abi |
IAbi: ה-Abi שאנחנו עובדים עליו כרגע. |
moduleId |
String: המזהה של המודול (בדרך כלל abi + שם המודול). |
includeFilters |
Map: מסנני הכללה מעוצבים ומנותחים. |
excludeFilters |
Map: מסנני ההחרגה המעוצבים והמנותחים. |
getModuleNamesMatching
public static Set<File> getModuleNamesMatching (File directory,
String suitePrefix,
String pattern)| פרמטרים | |
|---|---|
directory |
File |
suitePrefix |
String |
pattern |
String |
| החזרות | |
|---|---|
Set<File> |
השדה Set של מודולים שהשם שלהם מכיל את התבנית שצוינה. |
loadConfigsFromDirectory
public LinkedHashMap<String, IConfiguration> loadConfigsFromDirectory (List<File> testsDirs, Set<IAbi> abis, String suitePrefix, String suiteTag, List<String> patterns)
טעינה ראשית של הגדרות, חיפוש בתיקייה
| פרמטרים | |
|---|---|
testsDirs |
List |
abis |
Set |
suitePrefix |
String |
suiteTag |
String |
patterns |
List |
| החזרות | |
|---|---|
LinkedHashMap<String, IConfiguration> |
|
loadConfigsFromJars
public LinkedHashMap<String, IConfiguration> loadConfigsFromJars (Set<IAbi> abis, String suitePrefix, String suiteTag)
טעינה ראשית של ההגדרות, בדיקת המשאבים בנתיב המחלקה. (הגדרות TF לדוגמה).
| פרמטרים | |
|---|---|
abis |
Set |
suitePrefix |
String |
suiteTag |
String |
| החזרות | |
|---|---|
LinkedHashMap<String, IConfiguration> |
|
loadConfigsFromSpecifiedPaths
public LinkedHashMap<String, IConfiguration> loadConfigsFromSpecifiedPaths (List<File> listConfigFiles, Set<IAbi> abis, String suiteTag)
טעינה ראשית של ההגדרות, בדיקה של הקבצים שצוינו
| פרמטרים | |
|---|---|
listConfigFiles |
List |
abis |
Set |
suiteTag |
String |
| החזרות | |
|---|---|
LinkedHashMap<String, IConfiguration> |
|
loadTfConfigsFromSpecifiedPaths
public LinkedHashMap<String, IConfiguration> loadTfConfigsFromSpecifiedPaths (List<String> configs, Set<IAbi> abis, String suiteTag)
טעינה ראשית של ההגדרות, בדיקה של המשאבים שצוינו בנתיב המחלקה.
| פרמטרים | |
|---|---|
configs |
List |
abis |
Set |
suiteTag |
String |
| החזרות | |
|---|---|
LinkedHashMap<String, IConfiguration> |
|
setExcludedModuleParameters
public final void setExcludedModuleParameters (Set<ModuleParameters> excludedParams)
מגדיר את קבוצת ModuleParameters שלא צריך להתייחס אליהן בכלל.
| פרמטרים | |
|---|---|
excludedParams |
Set |
setFoldableStates
public final void setFoldableStates (Set<DeviceFoldableState> foldableStates)
מגדירה את קבוצת ה-DeviceFoldableState שצריך להפעיל.
| פרמטרים | |
|---|---|
foldableStates |
Set |
setIgnoreNonPreloadedMainlineModule
public final void setIgnoreNonPreloadedMainlineModule (boolean ignore)
ההגדרה הזו קובעת אם להתעלם מהתקנת המודול אם הוא לא נטען מראש.
| פרמטרים | |
|---|---|
ignore |
boolean |
setInvocationContext
public final void setInvocationContext (IInvocationContext context)
| פרמטרים | |
|---|---|
context |
IInvocationContext |
setLoadConfigsWithIncludeFilters
public final void setLoadConfigsWithIncludeFilters (boolean allowed)
הגדרת האפשרות הזו קובעת אם להטעין את הגדרות הבדיקה על סמך מסנן ההכללה שצוין.
| פרמטרים | |
|---|---|
allowed |
boolean |
setMainlineParameterizedModules
public final void setMainlineParameterizedModules (boolean allowed)
ההגדרה הזו קובעת אם לאפשר מודולים ראשיים עם פרמטרים.
| פרמטרים | |
|---|---|
allowed |
boolean |
setModuleParameter
public final void setModuleParameter (ModuleParameters param)
מגדיר את סוג ModuleParameters היחיד שצריך להפעיל.
| פרמטרים | |
|---|---|
param |
ModuleParameters |
setOptimizeMainlineTest
public final void setOptimizeMainlineTest (boolean allowed)
הגדרה שקובעת אם לבצע אופטימיזציה של בדיקת ה-mainline.
| פרמטרים | |
|---|---|
allowed |
boolean |
setOptionalParameterizedModules
public final void setOptionalParameterizedModules (boolean allowed)
ההגדרה הזו קובעת אם לאפשר מודולים אופציונליים עם פרמטרים.
| פרמטרים | |
|---|---|
allowed |
boolean |
setParameterizedModules
public final void setParameterizedModules (boolean allowed)
ההגדרה הזו קובעת אם לאפשר מודולים עם פרמטרים.
| פרמטרים | |
|---|---|
allowed |
boolean |
setUseIncludeFilterOrder
public final void setUseIncludeFilterOrder (boolean useIncludeFilterOrder)
קובעת אם לארגן את ביצוע הבדיקה לפי הסדר שצוין במסנן include.
| פרמטרים | |
|---|---|
useIncludeFilterOrder |
boolean |