[iOS]Xcode 11.4 new interesting features for automation

This article is a note for me in Xcode 11.4 https://developer.apple.com/documentation/xcode_release_notes/xcode_11_4_beta_release_notes/ Simulate push notification xcrun simctl push com.example.my-app ExamplePush.apns Like Android’s adb command, finally, we can simulate push notification on the local!! The local execution helped me so much when I achieved automation. Handle privacy permissions xcrun simctl privacy grant photos com.example.app, xcrun simctl privacy…More

“iOSテスト全書”を書きました

書籍を書きました。 iOSテスト全書 著者: 松尾 和昭,細沼 祐介,田中 賢治,平田 敏之,玉城 信悟, 製本版,電子版 PEAKSで購入する PEAKSから発売されている今までの書籍も拝見していますが、いずれもよくできていること、周りの期待感も高いこともあり、はじめに企画への参画を打診された時にどうしようかと悩んだことを覚えています。 iOSに対するわたしの持ち札はiOS全般のテストツールや、経験を含めた深さでいうとUIテストに関わる範囲です。あと、ソフトウェアテストや品質に関わる専門性のところでした。Appiumというネイティブアプリを主な対象としたOSSの自動化ツール開発も行っているので、テストツール側の挙動に対する知見なども持っていました。 結果、蓋をあけると1章と8章を書きました。そのほかの章は、主には概念的な話やツール、XCUITest付近でいうとちょっと突っ込んだところまで執筆時にレビューに参加したりしていました。8章では、XCUITestの内部挙動のような話にも踏み込もうと思ったのですが、文量や初学者という対象読者を考えるとXCTestツール近辺の知見を最低限要求する事になるので、発展的な内容に繋がるような言及は止めました。(例えばこんな付近の話) 個人的な想いとしては、ツールの使い方よりも基礎となる話をしるきっかけになって欲しいと思っていたので、1章も長くならないようにしつつも、ある程度話が飛ばされる方面の内容を文章に組み込んでみました。”人は間違える”という話や自動化に進んでいく話とかですね。同様の内容は数年前に社内ブログで書いたことがあるのですが、全般的に反応がよかったためです。”テスト技法”などに踏み込むときも、書籍などから辿ることもできるように。ここら辺はAndroidテスト全書にはない内容も含まれるので、Androidテスト全書購入者でも楽しむことができるかと思います。 ちなみに、他の章でもXCTest、XCTest(UI)などの話やそれらを使ったいくつかのテストコードの書き方、CI/CD環境の構築話もあります。iOSのテストに関わる入門書という位置づけでも、ツールの話だけではなく考え方も散りばめられているのでお勧めできる内容かなと思っています。 それでは、Happy Testing 🙂More

[Appium][iOS]handle dark mode via process arguments

Appium’s appium-ios-simulator has an ability to make simulator instance dark mode by issue. The ability affects entire system, but it works only on Simulator. We can handle the style in real devices, too, when the app has a logic to switch it in the code level. We also can control the configuration via process arguments…More

[iOS][XCTest][Appium]iOS13 returns different source structure

iOS 13 returns different source tree structure as the view hierarchy. Appium builds view hierarchy from accessibility snapshot. Users can search elements as XPath or class chain which find elements from the view hierarchy. They depend on the view hierarchy. Thus, if the hierarchy changes, we must re-struct the path for the view. We noticed…More

Read “iOSアプリ開発自動テストの教科”

I would put a note for iOSアプリ開発自動テストの教科 which is iOS testing (by XCTest, XCUITest) before. Recently I read only English book, though. (I forgot to leave here) The book isn’t new for me. That is for beginners who want to learn iOS test toolchain, focusing on how to use them. I purchased the beta of…More

[iOS][Appium]A note topics I dropped from the book

I’m writing a test automation book in Japanese. Then, I dropped some kind of deep dive into XCTest items since the logic is not for beginners. The target is a bit differ from the topics. I picked some words from the dropped list here. testmanagerd usbmux XCUITest runs methods on the main thread, run some…More