-Aug 29, 2019 - Release 0.3
+Aug 29, 2019 - Release 0.2
============================
- Implemented hour class
-
-Jun 22, 2019 - Release 0.2
-============================
-
- - Added date class
+ - Implemented date class
May 30, 2019 - Release 0.1
============================
# Process this file with autoconf to produce a configure script.
AC_PREREQ([2.69])
-AC_INIT([libACL], [0.3], [arjen@androemda.nl])
+AC_INIT([libACL], [0.2], [arjen@androemda.nl])
AM_INIT_AUTOMAKE([-Wall foreign])
AC_CONFIG_MACRO_DIRS([m4])
AC_CONFIG_FILES([Makefile src/Makefile test/Makefile doc/Makefile])
</item>
<item tag="date(unsigned day, string month, short year)">
</item>
-<item tag="date(string s)">
+<item tag="date(String s)">
</item>
</description>
</section>
<description>
<item tag="operator=(date &d)">
</item>
-<item tag="operator=(string &s)">
+<item tag="operator=(String &s)">
Parse string s and extract a day, month and year if the string contains an actual date.
</item>
</description>
<section>
<heading>Attributes</heading>
<description>
-<item tag="unsigned day()">
+<item tag="unsigned Day()">
</item>
-<item tag="unsigned month()">
+<item tag="unsigned Month()">
</item>
-<item tag="short year()">
+<item tag="short Year()">
</item>
</description>
</section>
-TESTS = $(check_PROGRAMS) date_today check_output
+TESTS = $(check_PROGRAMS) date_today hour_now check_output
AM_CPPFLAGS = -I../src
LDADD = ../src/.libs/libACL.la
check_PROGRAMS = string_assign string_basics string_compare string_cat string_substring string_regex \
date_assign date_parse date_compare date_arithmetic date_attributes date_check_today \
- hour_assign hour_parse hour_compare hour_arithmetic
+ hour_assign hour_parse hour_compare hour_arithmetic hour_check_now
string_assign_SOURCES = string_assign.cpp
string_basics_SOURCES = string_basics.cpp
hour_parse_SOURCES = hour_parse.cpp
hour_compare_SOURCES = hour_compare.cpp
hour_arithmetic_SOURCES = hour_arithmetic.cpp
+hour_check_now_SOURCES = hour_check_now.cpp
+
+hour_now : hour_check_now
/*******************************************************
* Unit test for the date class
*
- * test contrustor and assignment of Sting objects
+ * test if the today() function returns the system date
******************************************************
*
*/
--- /dev/null
+/*******************************************************
+ * Unit test for the hour class
+ *
+ * test if the now() function returns the system date
+ ******************************************************
+ *
+ */
+
+#include "date.h"
+#include <assert.h>
+
+int main(int argc, char *argv[])
+{
+ hour d0;
+
+ if (argc == 2)
+ {
+ String system_date(argv[1]);
+ hour d1(system_date);
+
+ d0 = now();
+ assert(d0 == d1);
+ }
+
+ return 0;
+}
+
--- /dev/null
+#!/bin/bash
+
+STATUS=0
+
+TODAY=`date`
+./hour_check_now "$TODAY"
+exit $?