27 Mart 2025'ten itibaren AOSP'yi derlemek ve AOSP'ye katkıda bulunmak için aosp-main yerine android-latest-release kullanmanızı öneririz. Daha fazla bilgi için AOSP'de yapılan değişiklikler başlıklı makaleyi inceleyin.
Koleksiyonlar ile düzeninizi koruyun
İçeriği tercihlerinize göre kaydedin ve kategorilere ayırın.
Uyumluluk Test Paketi (CTS), cihazlarınızın Android ile uyumlu olmasını sağlamak için kullanılan ücretsiz, ticari sınıf bir test paketi ve araçtır. CTS'nin, sürekli bir derleme sistemi aracılığıyla günlük iş akışınıza entegre edilmesi amaçlanmıştır. CTS, masaüstü bir makinede çalışır ve testleri doğrudan bağlı cihazlarda veya bir emülatörde yürütür. Android uyumluluğuna genel bakış için Android uyumluluk programına genel bakış başlıklı makaleyi inceleyin.
Şekil 1. CTS otomatik testi.
Şekil 1'de CTS otomatik testlerinin yürütülme süreci gösterilmektedir:
CTS'yi indirip yükleyin. Bu adımda test ortamını, test iş istasyonunu ve test ettiğiniz cihazı veya test edilen cihazı (DUT) da ayarlamanız gerekir.
CTS otomatik testlerini çalıştırın.
Sonuçları depolayın ve inceleyin.
Sorunları giderin ve testleri yeniden çalıştırın.
Uyumsuzlukları erkenden tespit etmek ve Android uygulamalarınızın geliştirme süreci boyunca uyumlu kalmasını sağlamak için CTS'yi kullanın.
CTS bileşenleri
CTS aşağıdaki temel bileşenleri içerir:
Ticaret Federasyonu
Test donanımı ve çerçevesi, testlerin otomatik olarak yürütülmesine olanak tanır.
CTS otomatik testleri
Trade Federation çerçevesini kullanan ve Trade Federation test donanımı kullanılarak çalıştırılabilen testler.
CTS Doğrulayıcı (CTS-V) testleri
Manuel olarak çalıştırılması gereken testler.
CTS Doğrulayıcı (CTS-V) uygulaması
CTS-V testleri yapmak ve CTS-V test sonuçlarını toplamak için kullanılan bir uygulama.
Test kaydı
DUT'da çalıştırılan tek bir test. Otomatik test durumları, JUnit testleri olarak Java'da yazılır ve cihaz hedefinde çalışacak şekilde paketlenmiş Android APK dosyalarıdır.
Test durumları birim testleri veya işlevsel testler olabilir. Birim test, Android platformundaki atomik kod birimlerini test eder. Örneğin, bir birim testi tek bir Android sınıfını test edebilir.
İşlevsel test, belirli bir kullanım alanı için kullanılan yöntemlerin ve sınıfların bir kombinasyonunu kullanır.
Test yapılandırması
DUT'da çalıştırılan belirli bir otomatik test grubu. Test yapılandırmaları, WORKING_DIRECTORY/cts/tools/cts-tradefed/res/config konumunda bulunan XML dosyalarıdır.
Tüm otomatik test durumlarını içeren test yapılandırmaları ve test durumlarının bir alt kümesini içeren test yapılandırmaları vardır.
Test modülü
Aynı özellik alanı için test durumları koleksiyonundan oluşan bir test yapılandırması.
Test planı
Test modülleri koleksiyonundan oluşan bir test yapılandırması.
Test kapsamı
Test durumları, uyumluluğu sağlamak için aşağıdaki alanları kapsar:
Bölge
Açıklama
İmza testleri
Her Android sürümü için, sürümde bulunan tüm herkese açık API'lerin imzalarını açıklayan XML dosyaları vardır. CTS, bu API imzalarını cihazda bulunan API'lerle karşılaştıran bir yardımcı program içerir. İmza kontrolünün sonuçları test sonucu XML dosyasına kaydedilir.
Platform API testleri
Platform (temel kitaplıklar ve Android Uygulama Çerçevesi) API'lerini, SDK Sınıf Dizini'nde belirtildiği şekilde test ederek API'nin doğru olduğundan emin olun. Doğru sınıf, özellik ve yöntem imzaları, doğru yöntem davranışı ve yanlış parametre işleme için beklenen davranışı sağlamak üzere negatif testler de yapmanız gerekir.
Dalvik testleri
Testler, Dalvik yürütülebilir biçimini test etmeye odaklanır.
Platform veri modeli
CTS, SDK android.provider paketinde (kişiler, tarayıcılar ve ayarlar dahil) belirtildiği gibi, içerik sağlayıcılar aracılığıyla uygulama geliştiricilere sunulan temel platform veri modelini test eder.
Platform amaçları
CTS, SDK'daki
Yaygın niyetler bölümünde belirtildiği gibi temel platform niyetlerini test eder.
Platform izinleri
CTS, SDK'da Manifest.permission belirtildiği gibi temel platform izinlerini test eder.
Platform kaynakları
CTS, SDK'daki
Kaynak türlerine genel bakış bölümünde belirtildiği gibi temel platform kaynak türlerinin doğru şekilde kullanılıp kullanılmadığını test eder. CTS testleri; basit değerler, çizilebilir öğeler, dokuz parça, animasyonlar, düzenler, stiller ve temalar ile alternatif kaynakların yüklenmesi ile ilgili testleri içerir.
Bu sayfadaki içerik ve kod örnekleri, İçerik Lisansı sayfasında açıklanan lisanslara tabidir. Java ve OpenJDK, Oracle ve/veya satış ortaklarının tescilli ticari markasıdır.
Son güncelleme tarihi: 2025-07-27 UTC.
[[["Anlaması kolay","easyToUnderstand","thumb-up"],["Sorunumu çözdü","solvedMyProblem","thumb-up"],["Diğer","otherUp","thumb-up"]],[["İhtiyacım olan bilgiler yok","missingTheInformationINeed","thumb-down"],["Çok karmaşık / çok fazla adım var","tooComplicatedTooManySteps","thumb-down"],["Güncel değil","outOfDate","thumb-down"],["Çeviri sorunu","translationIssue","thumb-down"],["Örnek veya kod sorunu","samplesCodeIssue","thumb-down"],["Diğer","otherDown","thumb-down"]],["Son güncelleme tarihi: 2025-07-27 UTC."],[],[],null,["# The Compatibility Test Suite (CTS) overview\n\n*Compatibility Test Suite (CTS)* is a free, commercial-grade test suite and\ntools used to help ensure that your devices are Android compatible. CTS is\nintended to be integrated into your daily workflow, such as through a\ncontinuous build system. CTS runs on a desktop machine and executes tests\ndirectly on attached devices or on an emulator. For an overview of Android compatibility, see [Android compatibility program overview](/docs/compatibility).\n\n**Figure 1.** CTS automated testing.\n\nFigure 1 shows the process of executing CTS automated tests:\n\n1. Download and install CTS. This step also involves setting up the test environment, the testing workstation, and the device you are testing or *device under test (DUT)*\n2. Run CTS automated tests.\n3. Store and review the results.\n4. Troubleshoot issues and rerun tests.\n\nUse CTS to reveal incompatibilities early, and to ensure that your Android\nimplementations remain compatible throughout the development process.\n\nCTS components\n--------------\n\nCTS contains the following major components:\n\n*Trade Federation*\n: A test harness and framework allow for the automated execution of tests.\n\n*CTS automated tests*\n: Tests that use the Trade Federation framework and can be run using the Trade\n Federation test harness.\n\n*CTS Verifier (CTS-V) tests*\n: Tests that must be run manually.\n\n*CTS Verifier (CTS-V) app*\n: An app used to conduct CTS-V tests and collect CTS-V test results.\n\n*Test case*\n\n: An individual test executed on the DUT. Automated test cases are\n written in Java as JUnit tests and packaged Android APK files to run on the\n device target.\n\n Test cases can be *unit tests* or *functional tests*. A unit test tests atomic\n units of code within the Android platform. For example, a unit test might test\n a single Android class.\n\n A functional test exercises a combination of methods and classes used for a\n specific use case.\n\n*Test configuration*\n\n: A specific set of automated tests that are run on the\n DUT. Test configurations are XML files located in\n \u003cvar translate=\"no\"\u003eWORKING_DIRECTORY\u003c/var\u003e`/cts/tools/cts-tradefed/res/config`.\n There are test configurations that contains all automated test cases and test\n configurations that contain a subset of test cases.\n\n*Test module*\n\n: A test configuration consisting of a collection of test cases for the same\n feature area.\n\n*Test plan*\n\n: A test configuration consisting of a collection of test modules.\n\n| **Note:** The Android Open Source Project accepts contributions to improve CTS just as for any other component. Improving the coverage and quality of CTS tests is one of the best ways to contribute to Android. To make contributions to CTS, follow the same process in [Submit code changes](/docs/setup/contribute/submit-patches).\n\nTest coverage\n-------------\n\nTest cases cover the following areas to ensure compatibility:\n\n| Area | Description |\n|----------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Signature tests | For each Android release, there are XML files describing the signatures of all public APIs contained in the release. The CTS contains a utility to check those API signatures against the APIs available on the device. The results from signature checking are recorded in the test result XML file. |\n| Platform API tests | Test the platform (core libraries and Android Application Framework) APIs as documented in the SDK [Class Index](https://developer.android.com/reference/classes) to ensure API correctness, including correct class, attribute and method signatures, correct method behavior, and negative tests to ensure expected behavior for incorrect parameter handling. |\n| Dalvik tests | The tests focus on testing the Dalvik executable format. |\n| Platform data model | The CTS tests the core platform data model as exposed to application developers through content providers, as documented in the SDK [`android.provider`](https://developer.android.com/reference/android/provider/package-summary) package (including contacts, browsers, and settings) |\n| Platform intents | The CTS tests the core platform intents, as documented in the SDK [Common intents](https://developer.android.com/guide/appendix/g-app-intents). |\n| Platform permissions | The CTS tests the core platform permissions, as documented in the SDK [`Manifest.permission`](https://developer.android.com/reference/android/Manifest.permission). |\n| Platform resources | The CTS tests for correct handling of the core platform resource types, as documented in the SDK [Resource types overview](https://developer.android.com/guide/topics/resources/available-resources). The CTS tests include tests for simple values, drawables, nine-patch, animations, layouts, styles and themes, and loading alternate resources. |\n\nWhat's next\n-----------\n\nAfter reading this document, continue to [Set up CTS](/docs/compatibility/cts/setup)."]]