Koleksiyonlar ile düzeninizi koruyun
İçeriği tercihlerinize göre kaydedin ve kategorilere ayırın.
Bu belgede, Test Lab IAM izinlerinin ve rollerinin yapılandırılmasıyla ilgili referans bilgileri verilmektedir. Daha ayrıntılı roller yapılandırmak istiyorsanız Test Lab, Android Studio kullanarak hem testleri yürütmek hem de cihazları yayınlamak için izinler sağlar. Test yürütme, IAM ve aktarım cihazları için izinlerin ve rollerin düzgün şekilde yapılandırılmasıyla ilgili ek şartlara sahiptir.
Test Yürütme İşlemi
Testleri çalıştırıp sonuçlarını okuyabilmek için Test Lab'ı doğru şekilde yapılandırmak üzere Cloud Storage paketlerine erişimi yapılandırmanız gerekir. Bu işlem için, standart Firebase önceden tanımlanmış rollerinde yer almayan belirli izinlerin yapılandırılması gerekir. Test Lab erişimi vermek için aşağıdaki seçeneklerden birini kullanın.
Uygulamanızı ayrı bir Firebase projesinde test edin.
Test Lab erişimi olan kullanıcıları ekleyin ve Firebase konsolunu kullanarak onlara eski proje rolleri atayın.
(İsteğe bağlı) Bir kullanıcının Test Lab ile test çalıştırmasına izin vermek için Düzenleyici proje rolünü atayın.
(İsteğe bağlı) Bir kullanıcının test sonuçlarını Test Lab ile görüntülemesine izin vermek için Görüntüleyici proje rolünü atayın.
gcloud CLI ile testler
gcloud CLI, Testing API veya Gradle Managed Devices'dan başlatılan testlerde varsayılan olarak Firebase tarafından oluşturulan bir Cloud Storage paketi kullanılır. Bunun için testi yürüten asıl kullanıcının Firebase projeniz için "roles/editor" rolüne sahip olması gerekir.
Bu rolü veremiyorsanız veya ayrıntılı test sonuçlarını 90 günden uzun süre saklamak istiyorsanız Cloud Storage--results-bucket gcloud komut satırı seçeneğini kullanarak bu test sonuçlarını sahip olduğunuz bir Cloud Storage
pakete gönderebilirsiniz.
Kendi Cloud Storage paketinizi kullanırken:
Google Cloud konsolunu kullanarak gerekli izin grubunu birlikte veren bir çift önceden tanımlanmış rol atayın.
Bir kullanıcının Test Lab ile test çalıştırmasına izin vermek için hem Firebase Test Lab Yöneticisi (roles/cloudtestservice.testAdmin) hem de Firebase Analytics Görüntüleyici (roles/firebase.analyticsViewer) rollerini atayın.
Bir kullanıcının Test Lab test sonuçlarını görüntülemesine izin vermek için hem Firebase Test Lab Görüntüleyici (roles/cloudtestservice.testViewer) hem de Firebase Analytics Görüntüleyici (roles/firebase.analyticsViewer) rollerini atayın.
Cihazda yayın özelliğinde izinleri etkinleştirme
Cihazda Yayın, Test Lab cihazlarında kullanılabilen ayrı bir özelliktir. Test Lab cihazlarına doğrudan erişmenizi sağlar. Firebase Düzenleyicileri ve Yöneticileri, Cihaz Akışı'nı ek roller olmadan kullanabilir. Ancak gerekirse daha ayrıntılı roller de sağlayabilirsiniz.
Bir kullanıcının cihaz akışını kullanmasına izin vermek için Google Cloud konsolunu kullanarak gerekli izinleri birlikte veren önceden tanımlanmış bir rol atayın
. Atanacak rol, Firebase Test Lab Doğrudan Erişim Yöneticisi'dir (roles/cloudtestservice.directAccessAdmin).
[[["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-09-06 UTC."],[],[],null,["\u003cbr /\u003e\n\nThis document provides reference information about configuring Test Lab IAM\npermissions and roles. If you want to configure more granular roles, Test Lab\nprovides permissions for both executing tests and streaming devices using\nAndroid Studio. Test execution has extra requirements to properly configure\npermissions and roles for IAM and the streaming devices.\n\nTest Execution\n\nTo properly configure Test Lab so that you can execute and read the results\nof tests, you have to configure access to Cloud Storage buckets. This\nrequires a specific configuration of permissions that aren't all included in the\nstandard [Firebase predefined roles](/docs/projects/iam/roles-predefined). To\ngrant access to Test Lab, use one of the following options.\n\nTests through the Firebase console\n\nFor tests started from Firebase console or through the [Firebase Test Lab Device Matrix in Android Studio](https://developer.android.com/studio/test/test-in-android-studio#run-with-firebase-test-lab):\n\n1. Test your app in a dedicated separate Firebase project.\n2. Add users that need Test Lab access and assign them legacy project roles using the [Firebase console](//console.firebase.google.com/).\n3. (Optional) Assign the **Editor** project role to allow a user to run tests with Test Lab.\n4. (Optional) Assign the **Viewer** project role to allow a user to view test results with Test Lab.\n\nTests through gcloud CLI\n\nTests started from the [gcloud CLI](/docs/test-lab/android/command-line),\nthe [Testing API](/docs/test-lab/reference/testing/rest), or [Gradle Managed\nDevices](/docs/test-lab/android/android-studio#gmd-testlab-plugin) use a\nCloud Storage bucket created by Firebase by default. This requires the\nprincipal executing the test to have the \"roles/editor\" role for your firebase\nproject.\n\nIf you cannot grant that role, or you want to retain detailed test results for\nlonger than 90 days, you can send these test results to a Cloud Storage\nbucket that you own using the\n[**--results-bucket** gcloud command-line option](//cloud.google.com/sdk/gcloud/reference/firebase/test/android/run).\n\nWhen using your own Cloud Storage bucket:\n\n1. Assign a pair of predefined roles, which grants the required set of permissions together, using the [Google Cloud console](//cloud.google.com/iam/docs/granting-changing-revoking-access).\n2. To allow a user to run tests with Test Lab, assign both: Firebase Test Lab Admin (`roles/cloudtestservice.testAdmin`) and Firebase Analytics Viewer (`roles/firebase.analyticsViewer`)\n3. To allow a user to view test results in Test Lab, assign both: Firebase Test Lab Viewer (`roles/cloudtestservice.testViewer`) and Firebase Analytics Viewer (`roles/firebase.analyticsViewer`)\n\n| **Caution:** Users assigned these predefined roles can access *all* Cloud Storage buckets associated with the Firebase project, potentially including customer data.\n\nEnable permissions in Device Streaming\n\nDevice Streaming is a separate feature built on top of Test Lab devices. It\nprovides you with direct access to Test Lab devices. Firebase Editors and\nAdmins can use Device Streaming without any additional roles, however, you can\nalso provide more granular roles if necessary.\n\nTo allow a user to use device streaming, assign a predefined role which grants\nthe required set of permissions together, using the [Google Cloud console](//cloud.google.com/iam/docs/granting-changing-revoking-access)\n. The role to assign is Firebase Test Lab Direct Access\nAdmin (`roles/cloudtestservice.directAccessAdmin`).\n\nFor more information on Device Streaming in Android Studio, see [Device Streaming in Android Studio](https://developer.android.com/studio/preview/android-device-streaming)."]]