Why is both 盐 (salt) and 咸 (salty) in 尝尝他们的盐一样咸的咸菜?
The part is actually fine. This is a parsing problem; the whole meaning is


  trying their pickled vegetables which taste as salty as (pure) salt



「鹹菜」does not just mean salty vegetables, it's the name of a specific dish known as Chinese pickles in English.
「鹽」is used as a measure of saltiness (in taste) between Chinese pickles and pure salt.




Note that salty is actually a measure of the richness of flavour of 鹹菜, so while translating the above into English (as salty as salt) sounds a bit unpleasant, it's meant to be a praise of the tastiness of the villagers' dishes.