#include <cstdlib>
#include <iostream>
#include <string>
#include <cmath>
#include "greet.h"
using namespace std;

/*--------
  signature: main: void -> int

  purpose: testing program for the function greet

  examples: when run, this should output to the screen:
testing greet: true's should mean passed:
---------------------------------------
...followed by each testing call, hopefully
   followed by true to show it passed

  by: funct_play
  last modified: Tue Oct 18 14:05:27 PDT 2016
--------*/

int main()
{
    cout << boolalpha;
    cout << endl;
    cout << "testing greet: true's should mean passed: " << endl;
    cout << "---------------------------------------" << endl;
    cout << "(greet(\"Calvin\", 1) == \"Good morning, Calvin!\"): " 
         << (greet("Calvin", 1) == "Good morning, Calvin!") << endl;
    cout << "(greet(\"Mary\", 13) == \"Good afternoon, Mary!\"): " 
         << (greet("Mary", 13) == "Good afternoon, Mary!") << endl;
    cout << "(greet(\"Steve\", 20) == \"Good evening, Steve!\"): " 
         << (greet("Steve", 20) == "Good evening, Steve!") << endl;
    cout << "(greet(\"Molly\", 0) == \"Good morning, Molly!\"): " 
         << (greet("Molly", 0) == "Good morning, Molly!") << endl;
    cout << "(greet(\"Sue\", 12) == \"Good afternoon, Sue!\"): " 
         << (greet("Sue", 12) == "Good afternoon, Sue!") << endl;
    cout << "(greet(\"Jimmy\", 18) == \"Good evening, Jimmy!\"): " 
         << (greet("Jimmy", 18) == "Good evening, Jimmy!") << endl;
    cout << "(greet(\"Sharon\", 23) == \"Good evening, Sharon!\"): " 
         << (greet("Sharon", 23) == "Good evening, Sharon!") << endl;
    cout << "(greet(\"Jackie\", -1) == \"Time too small - must be in [0, 23]\"): " 
         << (greet("Jackie", -1) == "Time too small - must be in [0, 23]") << endl;
    cout << "(greet(\"Bob\", 24) == \"Time too big - must be in [0, 23]\"): " 
         << (greet("Bob", 24) == "Time too big - must be in [0, 23]") << endl;
    cout << endl;

    return EXIT_SUCCESS;
}