Skip to content

Instantly share code, notes, and snippets.

@k-bx
Created February 10, 2014 23:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save k-bx/8926404 to your computer and use it in GitHub Desktop.
Save k-bx/8926404 to your computer and use it in GitHub Desktop.
Feature: Compute factorial
In order to play with Lettuce
As beginners
We'll implement factorial
Scenario: Backup at certain times
Given I have the time 18:00
Then I run server sync
Then I run server sync at 5:00
from lettuce import step
from lettuce import world
@step("I have the time 18:00")
def getting_time(step):
world.time = '18:00'
@step("I run server sync")
def server_sync_utcnow(step):
print '> server_sync_utcnow'
print ''
assert True
@step("I run server sync at \"(.*)\"")
def server_sync_at_date(step):
print '> server_sync_at_date'
print ''
assert False
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment