home.social

#xctest — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #xctest, aggregated by home.social.

  1. Interop between XCTest and Swift Testing? In the economy? It's more likely than you think.

    Legitimately, I'm really excited for this. This'll enable much more consistent set of tooling that can easily be used in Swift Testing and in XCTest. It'll also make migrating from XCTest to Swift Testing much more simpler and much safer.

    Go leave feedback at forums.swift.org/t/st-0021-tar

    #SwiftLang #XCTest #SwiftTesting #UnitTesting

  2. Also in related news: I updated my UI testing helpers library with a few macOS specific additions that I needed to test this application.

    github.com/Tunous/XCAppTest

    #Swift #XCTest #XCUITest

  3. Rafinad: сахар для UI-тестирования iOS-приложений

    Мы в hh очень любим UI-тесты, ими покрывается практически вся функциональность наших приложений, и даже backend-разработчики прогоняют тесты мобильных платформ перед развертыванием своих фич. Однако наши механизмы UI-тестирования разрабатывались более 8 лет назад и с тех пор почти не изменились. Кто-то скажет, что старые решения прошли проверку временем и что «работает — не трогай»... Возможно, и так. Но сейчас мы внедряем новую дизайн-систему, а новые компоненты требуют адаптации всех тестов — не лучшее ли время для перемен? Поэтому мы пересмотрели наши подходы к UI-тестированию и теперь готовы поделиться наработками с сообществом в виде open-source проекта — Rafinad . В этой статье расскажем, что он умеет и как им пользоваться.

    habr.com/ru/companies/hh/artic

    #ios #uiтесты #uiтестирование #тестирование #swift #swiftui #uikit #xctest #xcuitest #dsl

  4. Rafinad: сахар для UI-тестирования iOS-приложений

    Мы в hh очень любим UI-тесты, ими покрывается практически вся функциональность наших приложений, и даже backend-разработчики прогоняют тесты мобильных платформ перед развертыванием своих фич. Однако наши механизмы UI-тестирования разрабатывались более 8 лет назад и с тех пор почти не изменились. Кто-то скажет, что старые решения прошли проверку временем и что «работает — не трогай»... Возможно, и так. Но сейчас мы внедряем новую дизайн-систему, а новые компоненты требуют адаптации всех тестов — не лучшее ли время для перемен? Поэтому мы пересмотрели наши подходы к UI-тестированию и теперь готовы поделиться наработками с сообществом в виде open-source проекта — Rafinad . В этой статье расскажем, что он умеет и как им пользоваться.

    habr.com/ru/companies/hh/artic

    #ios #uiтесты #uiтестирование #тестирование #swift #swiftui #uikit #xctest #xcuitest #dsl

  5. Rafinad: сахар для UI-тестирования iOS-приложений

    Мы в hh очень любим UI-тесты, ими покрывается практически вся функциональность наших приложений, и даже backend-разработчики прогоняют тесты мобильных платформ перед развертыванием своих фич. Однако наши механизмы UI-тестирования разрабатывались более 8 лет назад и с тех пор почти не изменились. Кто-то скажет, что старые решения прошли проверку временем и что «работает — не трогай»... Возможно, и так. Но сейчас мы внедряем новую дизайн-систему, а новые компоненты требуют адаптации всех тестов — не лучшее ли время для перемен? Поэтому мы пересмотрели наши подходы к UI-тестированию и теперь готовы поделиться наработками с сообществом в виде open-source проекта — Rafinad . В этой статье расскажем, что он умеет и как им пользоваться.

    habr.com/ru/companies/hh/artic

    #ios #uiтесты #uiтестирование #тестирование #swift #swiftui #uikit #xctest #xcuitest #dsl

  6. Rafinad: сахар для UI-тестирования iOS-приложений

    Мы в hh очень любим UI-тесты, ими покрывается практически вся функциональность наших приложений, и даже backend-разработчики прогоняют тесты мобильных платформ перед развертыванием своих фич. Однако наши механизмы UI-тестирования разрабатывались более 8 лет назад и с тех пор почти не изменились. Кто-то скажет, что старые решения прошли проверку временем и что «работает — не трогай»... Возможно, и так. Но сейчас мы внедряем новую дизайн-систему, а новые компоненты требуют адаптации всех тестов — не лучшее ли время для перемен? Поэтому мы пересмотрели наши подходы к UI-тестированию и теперь готовы поделиться наработками с сообществом в виде open-source проекта — Rafinad . В этой статье расскажем, что он умеет и как им пользоваться.

    habr.com/ru/companies/hh/artic

    #ios #uiтесты #uiтестирование #тестирование #swift #swiftui #uikit #xctest #xcuitest #dsl

  7. Latest little hobby rabbit hole: automated iOS UI testing. It's always difficult for me to wrap my head around UI testing tools and frameworks, but I'm getting there! The least useful manual test cases for my app Playway are now automated. More useful ones to follow, hopefully. A good side effect is that I took the time to make sure all (OK, most) views have good accessibility settings.

    #ios #testing #UITesting #XCTest #accessibility #a11y

  8. Latest little hobby rabbit hole: automated iOS UI testing. It's always difficult for me to wrap my head around UI testing tools and frameworks, but I'm getting there! The least useful manual test cases for my app Playway are now automated. More useful ones to follow, hopefully. A good side effect is that I took the time to make sure all (OK, most) views have good accessibility settings.

    #ios #testing #UITesting #XCTest #accessibility #a11y

  9. I open sourced a new Swift Package.

    𝗫𝗖𝗨𝗜𝗧𝗲𝘀𝘁𝗛𝗲𝗹𝗽𝗲𝗿
    𝚇𝙲𝚄𝙸𝚃𝚎𝚜𝚝𝙷𝚎𝚕𝚙𝚎𝚛 𝚑𝚎𝚕𝚙𝚜 𝚢𝚘𝚞 𝚠𝚛𝚒𝚝𝚒𝚗𝚐 𝚄𝙸 𝚝𝚎𝚜𝚝𝚜 𝚠𝚒𝚝𝚑𝚒𝚗 𝚂𝚠𝚒𝚏𝚝𝚄𝙸. 𝙸𝚝 𝚙𝚛𝚘𝚟𝚒𝚍𝚎𝚜 𝚊 𝚜𝚎𝚝 𝚘𝚏 𝚞𝚜𝚎𝚏𝚞𝚕 𝚎𝚡𝚝𝚎𝚗𝚜𝚒𝚘𝚗𝚜 𝚘𝚗 𝚇𝙲𝚄𝙸𝙰𝚙𝚙𝚕𝚒𝚌𝚊𝚝𝚒𝚘𝚗, 𝚇𝙲𝚄𝙸𝙴𝚕𝚎𝚖𝚎𝚗𝚝 𝚊𝚗𝚍 𝚇𝙲𝚄𝙸𝙴𝚕𝚎𝚖𝚎𝚗𝚝𝚀𝚞𝚎𝚛𝚢 𝚝𝚘 𝚖𝚊𝚔𝚎 𝚢𝚘𝚞𝚛 𝚝𝚎𝚜𝚝𝚜 𝚖𝚘𝚛𝚎 𝚛𝚎𝚊𝚍𝚊𝚋𝚕𝚎 𝚊𝚗𝚍 𝚎𝚊𝚜𝚒𝚎𝚛 𝚝𝚘 𝚖𝚊𝚒𝚗𝚝𝚊𝚒𝚗.

    github.com/0xWDG/XCUITestHelpe

    #Swiftlang #XCTest #UITesting #Xcode #XCTestCase #SwiftUI #iOS #macOS #oss

  10. Had to knock off most of the last week after having come down with a bout of the the 'flu. But I did try @mattiem's suggestion of creating a separate #swift library package to be able to run #XCTest unit tests on code for a command line script. Works as expected.

  11. Введение в тестирование на Swift Testing

    XCTest является основным инструментом для тестирования в Swift и широко используется разработчиками. Однако, новая библиотека Testing предлагает дополнительные возможности и синтаксический сахар, который делает процесс тестирования еще более удобным и мощным. В данной статье мы рассмотрим основные аспекты тестирования на Swift, включая использование библиотеки Testing.

    habr.com/ru/articles/823396/

    #swift #testing #swift__разработка #swift_development #xcode #xctest

  12. How to specfiy file/directory in file open dialog in a UI test using XCTest?

    Using #XCTest for UI testing a #SwiftUI app, is it possible to specify a file/directory to be selected in a file open dialog? (Specifically, the one from a fileImporter call in SwiftUI; on both iOS and macOS.)

  13. 📡 If you work on #Xcode at #Apple, especially on #XCTest, please have a look at FB13673372, which included a reproducible sample project for test diamonds disappearing.

  14. It’d be awesome if swift-testing supported disabling of tests at runtime. We could plug @tuist Cloud into that and use data about flakiness to disable the execution of flaky tests. Or maybe that’s already possible with #XCTest

  15. Huh. Why does Swift's Mirror(reflecting:) only list properties, not methods?

    Is there an alternative way to get a list of all methods? How does XCTest do it when I define a testXX method?

    #swiftlang #xctest #xctestcase #mirror

  16. TIL: waitForExpectations(timeout:handler:) is called fulfillment(of:timeout:enforceOrder:) in asynchronous unit tests. #Swift #XCTest

  17. Stay Ahead of Bugs: How XCTests Can Keep Your iOS App Leak-Free!
    Detect memory leaks in your app using addTeardownBlock and a custom XCTestCase extension.
    #Swift #XCTest
    qualitycoding.org/swift-memory

  18. Since XCTest does not support async expressions in its assert functions I released SwiftAsyncAsserts Swift package to fill that gap.

    Write more readable testing code for your async type interfaces in Swift.

    github.com/angu-software/Swift

    #swift #xctest #asyncawait #unittest

  19. #Swift #SwiftUI #XCTest #SnapshotTesting

    I’m having trouble with Pointfreeco’s snapshot testing. Tests run and complete fine, but there’s a delay at the end of the test process. I can’t figure out where it’s coming from or what causes it. Reduced to a very simple fully reproducible example in my environment.

    Anyone have any ideas?

    github.com/pointfreeco/swift-s

  20. TIL about developer.apple.com/documentat:
    expectation(
    forNotification notificationName: NSNotification.Name,
    object objectToObserve: Any?,
    notificationCenter: NotificationCenter,
    handler: XCTNSNotificationExpectation.Handler? = nil
    )

    Extremely convenient for unit testing Notifications being sent. Nice!

    #iOSDev #XCTest

  21. “The best time to build a test was before the first commit. The next best time is now.” – Proverbious the Commitor, probably

    whynotestflight.com/excuses/he

    #XCode #XCTest #SwiftLang #UnitTesting #Equatable

  22. Anyone knows how to in iOS UI tests access text field present in navigation bar?

    I have editable title set using View.navigationTitle(_:) function and want to write UI test for it. But I don't see anything useful in the hierarchy when it is visible…

    #XCTest #UITesting #iOSDev #SwiftUI

  23. #Swift #XCTest #SnapshotTesting #XcodeCloud

    Point-Free has an excellent snapshot-testing library that lets you unit test your view snapshots (screenshots). It does not work with Xcode Cloud out of the box, because test runner environment in Xcode Cloud does not have access to the source repository, which snapshot-testing assumes by default.

    Here’s my solution for making snapshot-testing work correctly with Xcode Cloud. jaanus.com/snapshot-testing-xc

  24. #Swift enumerations: How to write #XCTest assertions to verify them? What about associated values? qualitycoding.org/unit-test-en

  25. Cool trick I learned for UI tests in Xcode. You can set "TZ" launch environment value to force the app to use provided time zone. Useful when testing layout that displays formatted dates.

    developer.apple.com/forums/thr

    #iOSDev #XCTest #UITesting #Swift

  26. #Swift enumerations: How to write #XCTest assertions to verify them? What about associated values? qualitycoding.org/unit-test-en

  27. #Swift enumerations: How to write #XCTest assertions to verify them? What about associated values? qualitycoding.org/unit-test-en

  28. In #XCTest, I declare all test methods as throws because it makes life easier, and there's no penalty. Can I do the same with MainActor at the class level? They're already running on the main thread, so this seems similar.

  29. #Swift enumerations: How to write #XCTest assertions to verify them? How do we test their associated values? Can we avoid overspecified tests? qualitycoding.org/unit-test-en

  30. I don’t know if I’m the person to make it, but I feel like a #Swift package to make doing all of the normal testing things #XCTest doesn’t give you would be pretty amazing.

    The equivalent would be how #Rails uses Minitest (by default) but then also adds a bunch of stuff of its own to make testing web apps easy.

  31. FB11933090: Provide option to follow Test Plan order in initializing Test Targets irrespective of "Run in Parallel" status

    #Xcode #XCTest

  32. If there's anyone out here who uses the #KIF framework to run UI tests via #XCTest and is using it with #SwiftUI I'd love your input on this issue, of a control that is tappable in practice, and via the Accessibility Inspector, but not in my KIF test: github.com/kif-framework/KIF/i