Applying GTest on iOS

1,481 views
Skip to first unread message

cssz

unread,
Nov 18, 2013, 11:57:07 AM11/18/13
to googletes...@googlegroups.com
Hi!

  I would like to apply GTest on iOS.

  I have the following questions :
  1. Is it possible to use it on device, and in simulator too?
  2. What are the iOS versions that are supported by GTest?
  3. Is there any "how-to setup guide" for iOS?

  Thanks for your help in advance!

Regards,
cssz

Ken Turkowski

unread,
Jan 7, 2014, 3:45:36 PM1/7/14
to cssz, Google C++ Testing Framework
One of the problems is that iOS does not like you to run command-line programs.
So you need to wrap it in an iOS app.
One of my coworkers did so on one of our unit tests, but there seems to be no easy way to do this with the other 40+ unit tests.

--
 
---
You received this message because you are subscribed to the Google Groups "Google C++ Testing Framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to googletestframe...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Keith Ray

unread,
Jan 8, 2014, 3:49:45 PM1/8/14
to Ken Turkowski, cssz, Google C++ Testing Framework
We usually link all our unit tests together, with the code-under-test, and somewhere put the following code in to execute all of them (maybe in an app delegate method, or in main)

   ...
   testing::InitGoogleMock(&argc, argv);
   ​return​ RUN_ALL_TESTS();

Excerpt From: Langr, Jeff. “Modern C++ Programming with Test-Driven Development”

--
C. Keith Ray
650-533-6535
https://dl.dropbox.com/u/686328/keith_ray_resume.pdf
http://agilesolutionspace.blogspot.com/
Reply all
Reply to author
Forward
0 new messages