BaşlayınÜcretsiz Başlayın

List with a custom length

You already saw a list preparation implemented as a fixture. But what if you also want to customize the preparation process? For example, one might want to set a custom length for a generated list. You can implement it with chain fixture requests by making the "length" a separate fixture; let's call it list_length(). In the end, you will have a test function that requests the list, and the list is then generated by requesting the list_length().

Bu egzersiz

Introduction to Testing in Python

kursunun bir parçasıdır
Kursu Görüntüle

Uygulamalı interaktif egzersiz

İnteraktif egzersizlerimizden biriyle teoriyi pratiğe dökün

Egzersizi başlat