added a main for testing