refactoring
added ifdef ifndef
refactoring
refactoring
refactoring tests