This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
script | |
# SET ENV | |
. /home/fstrzelecki/.virtualenvs/exirel/bin/activate | |
# UPSTART CONFIG | |
respawn | |
respawn limit 5 10 | |
# RUN UWSGI | |
exec uwsgi --master --die-on-term --socket :8091 --module exirel.wsgi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
from worldfp import calculate_next | |
from world import World | |
def test_calculate_next(): | |
# Three neighbors from True or False is True | |
assert calculate_next(False, [True] * 3 + [False] * 5) | |
assert calculate_next(True, [True] * 3 + [False] * 5) |