Flutter ऐप्स के लिए एक शक्तिशाली, बहुपлатफॉर्म ई2ई यूआई टेस्टिंग फ्रेमवर्क जो integration_test की सीमाओं को पार करता है और मूलभूत इंटरैक्शन का निपटान करता है।
सार्वजनिक जानकारी से बना चयन मार्गदर्शन। केवल संदर्भ हेतु।
Patrol एक बहुप्लेटफॉर्म एंड-टू-एंड UI परीक्षण फ्रेमवर्क है जो Flutter के लिए है, जो integration_test की क्षमता से आगे बढ़ता है और मूल प्लेटफॉर्म की सुविधाओं के साथ निरंतर अंतरक्रिया की अनुमति देता है। यह परीक्षणकर्ताओं को Android, iOS, Web और macOS पर वास्तविक उपयोगकर्ता व्यवहार का अनुकरण करने की अनुमति देता है, जिसमें मूल डायलॉग, अनुमतियाँ और प्रणाली-स्तरीय क्रियाकलाप शामिल हैं। विश्वसनीयता और डेवलपर अनुभव के लिए बनाया गया, Patrol जटिल परीक्षण परिदृश्यों को सरल बनाता है जबकि क्रॉस-प्लेटफॉर्म सुसंगतता बनाए रखता है। इसकी वास्तुकला वास्तविक ऐप उपयोग को दर्शाने वाले विश्वसनीय और बनाए रखने योग्य परीक्षण सेट को समर्थन देती है।
उपयोग
नेटिव डायलॉग इंटरैक्शन का परीक्षण
प्लेटफॉर्म-विशिष्ट व्यवहार की पुष्टि करना
क्रॉस-प्लेटफ़ॉर्म UI सत्यापन
रनटाइम अनुमतियों का प्रबंधन
उपकरण-विशिष्ट घटनाओं का अनुकरण
एंड-टू-एंड वर्कफ़्लो वेरिफ़िकेशन
मुख्य विशेषताएँ
मूल इंटरैक्शन समर्थन
मल्टीप्लेटफॉर्म परीक्षण (Android, iOS, Web, macOS)
integration_test की तुलना में सुधारित परीक्षण विश्वसनीयता
वास्तविक उपयोगकर्ता सिमुलेशन
एम्बेडेड पुनर्प्रयास और प्रतीक्षा तंत्र
स्पष्ट, पठनीय परीक्षण सिंटैक्स
इनके लिए उपयुक्त
जटिल Flutter ऐप्स बनाने वाली टीमें
मूल सुविधा परीक्षण की आवश्यकता वाले विकासकर्ता
प्लेटफॉर्म के बीच सुसंगत E2E परीक्षण की आवश्यकता वाले प्रोजेक्ट
टेस्ट ऑटोमेशन इंजीनियर्स
CI/CD पाइपलाइन एंटीग्रेशन
विचार योग्य बातें
basic integration_test की तुलना में अतिरिक्त सेटअप की आवश्यकता होती है
प्लेटफॉर्म-विशिष्ट कॉन्फ़िगरेशन की आवश्यकता हो सकती है
परीक्षण के लिए समर्पित कार्य प्रवाह वाले परिपक्व प्रोजेक्ट्स के लिए सबसे उपयुक्त
मुख्यधारा के पैकेजों की तुलना में सीमित दस्तावेज़
नए उपयोगकर्ताओं के लिए अधिक शिक्षा वक्र
मूल README
संबंधित सोर्स रिपॉज़िटरी के मूल README का स्नैपशॉट। नवीनतम सामग्री के लिए रिपॉज़िटरी देखें।
Patrol
A powerful, multiplatform E2E UI testing framework for Flutter apps that overcomes the limitations of integration_test by handling native interactions. Developed by LeanCode since 2022, battle-tested and shaped by production-grade experience.
Patrol is an open-source framework created and maintained by LeanCode.
However, if your company wants to scale fast and accelerate Patrol’s
adoption, we offer a set of value-added services on top of the core framework.
[!NOTE]
Patrol 4.7.0 adds Swift Package Manager support for iOS and macOS!
If you migrate your project to SPM, a few small setup changes are needed — see the iOS setup guide for details.
Patrol custom finders
Flutter's finders are powerful, but not very intuitive to use.
We took them and made something awesome.
Thanks to Patrol's custom finders, you'll take your tests from this:
Flutter's default integration_test package can't interact with the OS your
Flutter app is running on. This makes it impossible to test many critical
business features, such as:
granting runtime permissions
signing into the app which through WebView or Google Services
The CLI is needed to enable Patrol's native automation feature in integration
tests. It also makes development of integration tests much faster thanks to [Hot
Restart].
To run widget tests, you can continue to use flutter test.
See .github/WORKFLOWS.md for detailed documentation about all GitHub Actions workflows, including test schedules, Flutter versions, and deployment pipelines.