Showing our App-driven MVNO at LTE World

Posted on 7/05/2013 by Erik Schultink, CTO

Last week, I joined a panel and gave a brief talk at LTE World Summit in Amsterdam, describing how we combine our apps with our MVNO.  Many of the operators attending LTE World loved the “app-driven” approach.  There’s growing interest from operators to use applications to drive innovation, create service differentiation, and engage more deeply with subscribers. In particular, there was a lot of positive feedback for the Zerolímites proposition, which uniquely exploits our apps to fulfill a clear subscriber need.

The full slide deck is linked below, but here a few key points from my talk:

  • We see our app as a way to add value to our service and differentiate it from traditional operators.
  • The combination of VoIP/messaging with the Zerolímites proposition is a novel way to create value for our own subscribers and incentivize distribution of the app to their friends who are still on other operators.
  • With voicemail, social calling history, cloud-based account management – we believe we’ve only just begun to scratch the surface on the possible innovation in this space.

Full slide deck here.

TUDelorean: Because for testing, it shouldn’t matter what time it is

Posted on 7/01/2013 by Daniel Rodríguez, Mobile Apps Engineer

Marty:  “Wait a minute. Wait a minute. Doc, uh…  Are you telling me that you built a time machine… out of a DeLorean?”
Doc:  “Yes, the way I see it, if you’re gonna build a time machine into a car, why not do it with some style?”

Here at Tuenti, testing culture is not only applied to the “server side”: native platforms are also tested as thoroughly as possible in order to provide products of the highest quality to our users. Today, we announce the release of a small part of our unit testing infrastructure for iOS platforms: TUDelorean.

We use many open source projects while developing the iOS app: from the LLVM compiler included in Xcode, to third party libraries that allow us to code faster during development. We rely almost exclusively on open source projects for testing: we use both OCHamcrest and OCMockito for our unit tests, and Frank for acceptance testing. We have already made several small contributions to some of the projects we use daily, but we had never published our own code as open source until now.

During the development of one of our latest features, we needed to unit test several modules that were dependent on the current time and check the results of some time calculations. Sometimes while writing the tests, we made assumptions like “if I need a date next month, I will just add 31 days to the current date”, which will make our test fail if it is run on January 31st. This is what we call “cinderella tests” in Tuenti (they stop working at midnight).

Reliability and reproducibility are two of the characteristics that all test should follow. Tests that might fail, or tests that cannot be repeated, are useless. After searching a little and seeing that no one had done anything similar, we decided to design and implement our own system to travel in time during our tests.

Time travel allows us to set up a reproducible scenario in our tests. In fact, it allows us to set up any scenario we need, like what would happen in our app on the 29th of February, how the app works in the Canary Islands time zone (our budget doesn’t allow us to be sent to the Canaries for a week in order to test the app), or how things work when daylight saving time starts or ends. Bigger fish have failed to implement those conditions properly.

Since we were so happy with our new code, and our consistently green tests, we thought that the system would be useful for almost anyone that needs to deal with time, dates and time zones in their iOS apps. The system is very easy to install (we even have a podspec, if case you are using CocoaPods), and the API is very easy to learn (you can refer to the project README file for details). You should be coding time independent tests in less than half an hour.
Why are we publishing this code? A couple of weeks ago, we came across the Put Objective-C Back On The Map movement, which attempts to raise the Objective-C community interest in open source and how important it is in our daily lives. Since we were going to release the code anyway, we decided to hold it back a little bit, and properly take part in the movement.
In the end, we simply hope that you’ll find this project as useful as we have, and that it inspires you to publish another small part of your own code as open source, so we all can benefit from it.

(Photo credit: davidgsteadman at Flickr)

Video Recordings of Browser Tests

Posted on 6/18/2013 by David Santiago, Test Engineer Senior

As part of the automated tests suite we run for every release candidate here at Tuenti, there are over 300 webdriver tests. They are used to verify that the site behaves as expected from the user’s point of view.

If you have ever dealt with these kinds of end-to-end tests, you know they are more prone to nondeterministic behavior than smaller, more focused integration tests. That’s expected given the higher number of moving parts involved. Our Jenkins continuous integration setup deals with these kinds of issues by retrying failed tests before considering them actual errors, helping to reduce the noise they cause.

Retrying a failed test that later passes wastes resources in our build pipelines, yet there is an even larger cost associated with them: the search for the root cause of the wrong behavior.

We already store screenshots for failed tests alongside their stack trace to help diagnose problems, but with some corner cases it’s not enough and it’s not uncommon for those tests to work perfectly fine when debugged locally. In those cases, the developer / test engineer working on it would have to be in front of the failed test when it ran in our CI environment, which is obviously not possible.

Therefore, we extended our webdriver grid infrastructure in order to record and store videos for the execution of such tests. Here is a diagram of the overall architecture, with additions to the previous one:

We implemented a video recording web service that runs on each server (actually virtual machines), where webdriver nodes for our grid run. This service allows the video recording in a VM to remotely start and stop in addition to storing it with a given name. For the video recording itself we used the Monte Media java library, extending it a bit to fit our needs.

By taking advantage of the hooks available in the code of the webdriver grid code, we transparently start the recording of the video whenever a new browser session is requested. From that moment on, the video is recorded while the test runs. If the test fails, our webdriver client api allows to request the storage of the video with a proper name that is afterwards used to access it. Another extension in the form of a servlet registered in the webdriver grid server allows the performance of such a request. The servlet knows where the node for the given test is located and asks the video service running there to stop and save the video.

Now, whenever a browser test fails in a build, a link to the video that was recorded during its execution is provided as part of the error information for the test, besides the failed assertion message and the stack trace.

We’d like to thank Kevin Menard for his support in the selenium users group and, for being available to help when someone needed it.

And the #TuentiChallenge3 winners are...

Posted on 5/24/2013 by Jorge Lería, Engineer, & Rosa Gutiérrez, Senior Engineer

The most difficult Tuenti programming challenge yet has come to an end with great results! Congratulations to all of those who were finalists out of the 3,900 participants! After a day of workshops and talks that our engineers gave to the 10 finalists in our office in Madrid, we’ve finally chosen the 3 winners of the 3rd edition of the Tuenti Challenge based on having correctly solved the problems, they type of algorithms they used and the quality of the code, among other factors:
1. Enric C.
2. Lander R.
3. Borja M.

The participants who also made it to the end of this edition were:

1. Daniel A.
2. Alfredo B.
3. Shoghi C.
4. Alejandro J.
5. Pedro L.
6. Javier M.
7. Rober M.

Our first contact with the contest finalists of the Tuenti Challenge took place at a BBQ with our CEO, Zaryn Dentzel. Our typical Tuenti style company culture was shining through, and the contestants met some of our employees in a very relaxed and informal setting.

During the day at our office, work sessions were held with our engineers along with workshops and interviews with Human Resources that made up this final phase of #TuentiChallenge3 before choosing the winners. The workshops were carried out by:

1. Miguel Lara, Mobile Apps Engineer Lead: 10 things we learnt becoming mobile. (in other words we messed up and you needn’t)
2. Jesús Bravo, Backend Engineer Senior: Scalability at Tuenti
3. David Iglesias, Software Engineer Senior: Travel for free with Tuenti
4. Luis Peralta, VP Engineering: Product Development at Tuenti
5. Davide Mendolia, Software Engineer Lead: Tuenti Life Cycle

At the end of the afternoon, we announced the name of the winners in our office in Madrid with the entire Tuenti staff celebrating the now mythic programming contest used to strengthen our engineering team. Thanks to all of the participants for all of the dedication and effort put into each of the problems, and for getting better and better with each edition. See you next year!

Meeting the Tech Team: Javier Mellado

Posted on 5/21/2013 by Eng Outreach Committee

Javier Mellado, born and raised in Malaga, moved to Madrid in 2006 and is the veteran member of the Software Engineering team at Tuenti. Since joining the company in September 2007, he’s worked on the technical side of user support. The Admin Tools team builds tools that help to manage Tuenti's content quality in terms of spam, underage users, prohibited content, etc.

If you want to get to know him a little better, don't miss the video we've made of him ;)

Pages

Follow us