aboutsummaryrefslogtreecommitdiff
path: root/test/cxxtest/sample/mock/Dice.cpp
blob: afd0641ac19a0cc38acb32e5191353fe90657071 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#include <T/stdlib.h>
#include "Dice.h"

Dice::Dice()
{
    T::srand( T::time( 0 ) );
}

unsigned Dice::roll()
{
    return (T::rand() % 6) + 1;
}