(a) An ionic compound that contains chlorine is sodium chloride (NaCl) and a covalent compound that contains chlorine is hydrogen chloride (HCl).
(b) The test to find out which water soluble compound, A or B, is ionic can be done by the electrical conductivity test. The compound solution that conducts electricity must be ionic in nature and the other compound solution that does not conduct electricity must be covalent in nature.