اعتبارًا من 27 آذار (مارس) 2025، ننصحك باستخدام android-latest-release
بدلاً من aosp-main
لإنشاء AOSP والمساهمة فيه. لمزيد من المعلومات، يُرجى الاطّلاع على التغييرات في AOSP.
بدء استخدام TF
تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
Trade Federation هي بنية اختبار كبيرة يمكن تكييفها مع مجموعة كبيرة من
حالات الاستخدام المختلفة، ومن المحتمل أن يحتاج معظم المستخدمين إلى مجموعة فرعية فقط من وظائفها. أولاً،
نتوقع أن ينفّذ مستخدمو TF أيًا من الأدوار الأساسية الثلاثة التالية: المطوّر والمُدمِج و
مُشغِّل الاختبار. قد يلعب شخص معيّن أيًا من هذه الأدوار الثلاثة (أو كلها)، ولكننا نعتقد أنّ
التمييز بين الأدوار سيساعد في تسهيل التنقّل في المستندات.
المطورون
يقضي المطوّرون معظم وقتهم في إنشاء وحدات TF مكتوبة بلغة Java.
وقد يكتبون إعدادات وينفذون اختبارات، ولكنهم عادةً ما يفعلون ذلك للتأكّد من أنّه يتم استدعاء
الوحدات بشكلٍ صحيح وأنّها تعمل على النحو المتوقّع.
الشركات المُدمجة
يقضي مُدمِجو الأنظمة معظم وقتهم في إنشاء إعدادات اختبار XML أو ملفات ملفّات التوجيه (التي يتم كتابتها بلغة بسيطة تشبه لغة برمجة شل). وتربط هذه الوحدات بين وحدات TF التي يكتبها المطوّر وإعدادات معيّنة مطلوبة لمتطلبات اختبار معيّنة وأهدافه.
اختبارات الأداء
يقضي مشغّلو الاختبارات معظم وقتهم في تنفيذ الاختبارات والتأكّد بشكل عام من
أنّه يتم إنشاء نتائج الاختبار وأنّ نتائج الاختبار التي تم إنشاؤها ذات صلة
ويمكن إعادة إنتاجها ودقيقة. ويقضون معظم وقتهم في التفاعل مع
واجهة سطر الأوامر في أداة tradefed، كما سيتحقّقون أيضًا من أنّ النتائج منطقية.
للاستفادة إلى أقصى حد من "اتحاد التجارة"، يجب تمثيل الأدوار الثلاثة.
على المطوّرين والمدمجين جعل TF تتفاعل مع أجزاء أخرى من البنية الأساسية،
مثل أنظمة الإنشاء ومستودعات نتائج الاختبار. على مُدمِجي الاختبار ومسؤولي تنفيذ الاختبار مساعدة
TF على تنفيذ الاختبارات المطلوبة وتحقيق النتائج المطلوبة. على مشغّلي الاختبار تحديد النتائج غير المنطقية والعمل مع المطوّرين وموفّري الدمج لتحديد مواضع الأخطاء وإصلاحها.
الخطوات التالية
على الأشخاص الذين يشغلون الأدوار الثلاثة مراجعة جميع المستندات الأخرى على الأقل.
سينقلك إعداد الجهاز إلى المرحلة التي يمكنك فيها تشغيل TF (من خلال إنشائه أو تنزيله).
سيوضّح قسم العمل مع الأجهزة كيفية إجراء الاختبارات باستخدام جهاز فعلي أو محاكي أو بدون استخدام أي جهاز على الإطلاق. ستوضّح صفحة
رحلة الاختبار من منظور نظري كيفية تفاعل أدوار
المطوّر والمُدمِج ومسؤول بدء الاختبار، ثم توضّح صفحة
معالجة الخيارات كيفية تطبيق هذه النظرية على أرض الواقع.
أخيرًا، يرشدك المثال الشامل إلى تطوير اختبار قياسي ودمجه ونشره. ويتضمن جوانب من كل دور، ومن المفترض أن يوفّر نصائح حول كيفية تنفيذ إجراءات أكثر تعقيدًا
لا يتم مناقشتها مباشرةً في المستندات.
إذا اطّلعت على كل المعلومات الواردة هنا وبقي لديك أسئلة لم تتم الإجابة عنها، جرِّب أولاً
الاطّلاع على رمز المصدر الخاص باتحاد التجارة. بالإضافة إلى ذلك، يمكنك تجربة طرح السؤال على مجموعة Google الخاصة بمنصّة
android. للحصول على أفضل النتائج، احرص على ذكر "اتحاد التجارة" (أو "اتحاد التجارة" أو "اتحاد التجارة") في موضوع الرسالة.
يخضع كل من المحتوى وعيّنات التعليمات البرمجية في هذه الصفحة للتراخيص الموضحّة في ترخيص استخدام المحتوى. إنّ Java وOpenJDK هما علامتان تجاريتان مسجَّلتان لشركة Oracle و/أو الشركات التابعة لها.
تاريخ التعديل الأخير: 2025-07-27 (حسب التوقيت العالمي المتفَّق عليه)
[[["يسهُل فهم المحتوى.","easyToUnderstand","thumb-up"],["ساعَدني المحتوى في حلّ مشكلتي.","solvedMyProblem","thumb-up"],["غير ذلك","otherUp","thumb-up"]],[["لا يحتوي على المعلومات التي أحتاج إليها.","missingTheInformationINeed","thumb-down"],["الخطوات معقدة للغاية / كثيرة جدًا.","tooComplicatedTooManySteps","thumb-down"],["المحتوى قديم.","outOfDate","thumb-down"],["ثمة مشكلة في الترجمة.","translationIssue","thumb-down"],["مشكلة في العيّنات / التعليمات البرمجية","samplesCodeIssue","thumb-down"],["غير ذلك","otherDown","thumb-down"]],["تاريخ التعديل الأخير: 2025-07-27 (حسب التوقيت العالمي المتفَّق عليه)"],[],[],null,["# Get started with TF\n\nTrade Federation is a large test infrastructure that can be adapted to a great variety of\ndifferent usecases, and most people will probably only need some subset of its functionality. First\noff, we envision that TF users will fulfill any of three primary roles: Developer, Integrator, and\nTest Runner. A particular individual might wear any (or all) of those three hats, but we feel the\ndistinction will help make it easier to navigate the documentation.\n\nDevelopers\n----------\n\nDevelopers spend the majority of their time creating TF modules that are written in Java.\nThey may write configurations and execute tests, but will typically only do so to verify that their\nmodules are being invoked properly and are functioning as expected.\n\nIntegrators\n-----------\n\nIntegrators spend the majority of their time creating XML test configurations, or command\nfiles (which are written in a simple shell-like language). They tie together TF modules written\nby the Developer with specific configurations that are required for particular test requirements and\ngoals.\n\nTest Runners\n------------\n\nTest Runners spend the majority of their time executing tests and generally making sure\nthat test results are being generated, and that the generated test results are relevant,\nreproducible, and accurate. They spend the majority of their time interacting with tradefed's\ncommand line interface, and will also verify that the results make sense.\n\nIn order to get the most out of Trade Federation, all three roles will need to be represented.\nIt will take Developers and Integrators to make TF interoperate with other pieces of infrastructure,\nlike build systems and test result repositories. It will take Integrators and Test Runners to get\nTF to actually run the desired tests and produce the desired test results. It will take Test\nRunners to identify results that don't make sense, and to work with the Developers and\nIntegrators to figure out where the bugs may lie and get them fixed.\n\nWhat's next\n-----------\n\nPeople in all three roles should at least glance through all the rest of the docs.\n[Machine Setup](/docs/core/tests/tradefed/fundamentals/machine_setup) will get you to the point where you can run TF (by building or downloading it).\n[Working with Devices](/docs/core/tests/tradefed/fundamentals/devices) will explain how to run tests with a physical device, with an emulator, or\nwith no device at all. The\n[Test Lifecycle](/docs/core/tests/tradefed/fundamentals/lifecycle) page will explain from a theoretical perspective how the roles of the\nDeveloper, Integrator, and Test Runner interact, and then\n[Option Handling](/docs/core/tests/tradefed/fundamentals/options) will demonstrate how to put that theory into practice.\n\nFinally, the [End-to-End Example](/docs/core/tests/tradefed/fundamentals/full_example) takes you through the development, integration, and deployment of a sample\ntest. It involves aspects of each role, and should offer hints at how to do more complicated\nthings that aren't directly discussed in the documentation.\n\nIf you've gotten through everything here and still have unanswered questions, first try taking\na look at the [Trade Federation source code](https://android.googlesource.com/platform/tools/tradefederation/+/main). Beyond that, feel free to try asking on the\n[android-platform](/docs/setup/community) Google Group. For best results, make\nsure to mention \"Trade Federation\" (or \"tradefed\", or \"TF\") in the message subject."]]