what is the relationship between hypothesis testing, statistical significance, and Type I and II errors

You start with a null hypothesis and an alternative hypothesis. You decide what probability you will use to reject your null hypothesis, in other words what is statistically significant. That is also your type I error, the probability of rejecting your null hypothesis, when it is really true. Type II error is the probability of accepting your null hypothesis when it is really false.