copy and equality constructors and tests