add test for nil and empty properties. truncate text buffer at start and end tags.