created unittest code