Last monday Apple gave us a sneak peek at iOS 7. This update introduces a bold new visual style for an OS which was, frankly, starting to look a little stale1. Although I like the direction Apple took I think the execution is severely lacking. Especially some of the icons are atrocious. What I find interesting about the new look though is the blend of flat design with the use of distinct visual panes. It makes the OS look a bit less sterile than Windows (Phone) 8 for example. iOS 7 does have some of the same downsides as other flat UIs, most notably the buttons which I always fail to recognize as buttons2.
I’m really hoping this was an early look and the final version is way more polished than the peek Apple gave us this week. I think Joshua Topolsky nails it in his article on The Verge:
Apple is showing that it can adapt, borrow, and tweak ideas from the competition, that it can expand what iOS feels and looks like as well as what it can do. The problem now is that it seems to be buckling a bit under the weight of an end-to-end redesign. I’m hopeful that in the next few months, as Apple ramps up for the introduction of new hardware at its fall event, some of the design and functionality issues that have yet to be addressed will be nipped and tucked.
I still prefer it over its direct competitors though.↩
This is a problem in most flat designs I’ve seen to date.↩
This post was automatically published by Wercker! Wercker is a Dutch startup company which aims to make continuous delivery easy. I just added the Github repository of my Octopress blog, added a YAML file, and clicked some buttons in a slick web interface and my blog posts are automatically published once I push them to GitHub. Nice!
As a recent newcomer to the Groovy and Grails world I only recently discovered Spock. Spock is a testing and specifications framework for Groovy applications (but Java apps are welcome too!).
One of the nice features of Spock is the support for so-called blocks. These blocks start with simple labels like when and then. These labels can even be decorated with a nice description which explains in natural language what the blocks are intended for.
Most of the examples of Spock specifications look like this:
123456789
def'pushing an element on the stack'(){// A nice description of the feature!when:// This is an example of a block, it starts here and ends at the next block or the end of the method.stack.push(elem)then:// These blocks don't even have labels, I'll show them in a minute!!stack.emptystack.size()==1stack.peek()==elem}
+Title: Customer withdraws cash+ As a customer, I want to withdraw cash from an ATM, so that I don’t have to wait in line at the bank.
One of the possible given-when-then scenarios looks like this:
+Scenario 1: Account is in credit+ Given the account is in credit And the card is valid And the dispenser contains cash When the customer requests cash Then ensure the account is debited And ensure cash is dispensed And ensure the card is returned
Unfortunately, I couldn’t find anything hinting at support for these scenarios using Spock (like given and and blocks). As per usual, I wasn’t looking very well as Spock gives you all the needed information in its documentation. I wrote this blog post anyway just to help the folks googling for “spock given-when-then” and “spock acceptance criteria” (and to remind myself of my own oversight of course!).
Using Spock’s aforementioned support for blocks and labels one could implement the scenario above as follows:
1234567891011121314151617181920212223242526
def'Account is in credit'(){given:'the account is in credit'// Look a label! Like I promised earlier!defaccount=newAccount()account.credit=2000and:'the card is valid'defcard=newCard()card.valid=truecard.account=accountand:'the dispenser contains cash'defdispenser=newDispenser()dispenser.cash=25000when:'the customer requests cash'dispenser.requestCash(100,card)then:'ensure the account is debited'account.credit==1900// No explicit assertion API, lovely! and:'ensure cash is dispensed'dispenser.cash==24900and:'ensure the card is returned'!dispenser.hasCard}
I think it looks and reads great! What I especially like about Spock is that it’s really flexible and powerful but has a minimalist syntax.
So, are you still looking for nice specification framework for Groovy (or Java)? Stop looking, go download Spock!
Fascinating article about a guy who decides to become a publicly traded person. Shareholders vote on pretty much every big decision he makes.
Then, on August 10, 2008, Merrill asked the shareholders to decide whether he should get a vasectomy. He didn’t tell McCormick that he was going to bring them in on it. As the CEO of himself, he simply wrote a note to his shareholders explaining his position on the subject. “Children are a financial drain,” Merrill wrote. “The time investment of raising a child is immense. The responsibility is epic. The impact on future projects would be drastic. In light of these factors, it makes sense to reduce the chances to nearly zero and have a vasectomy performed.”