Correct way to do a difference in means bootstrap Say I want to find the confidence interval for the difference in means and I have these numbers: For A: c(1, 2, 3) and for B c(4, 5, 6).  Should every replicate take samples independently or is it allowed to have a replicate where I only get samples from one of the groups?  
Example data set:   
test_data <- data.frame(person = c(rep("A", 3), rep("B", 3)),
       number = c(1:6))


  person number
1      A      1
2      A      2
3      A      3
4      B      4
5      B      5
6      B      6

I.e. can I have a bootstrap replication with the following result:
  person number
1      B      6
2      B      6
3      B      6
4      B      6
5      B      6
6      B      6

 A: One cannot expect a bootstrap procedure on two samples of size $3$ to be
accurate. So we have to regard this as an experiment to see how
the bootstrap performs in an unintended setting. 
The quick answer to
your question about the re-sampling procedure is that we have 2-sample data, and it is necessary to
keep the two samples separate when re-sampling for a nonparametric bootstrap CI.
We seek a 95% confidence for $\delta = \mu_x - \mu_y.$
If we knew the distribution of the difference $D = \bar X - \bar Y$ in sample means,
we could find $L$ and $U$ with
$$.95 = P(L \le D - \delta \le U) = 
P((\bar X - \bar Y)-U \le  \delta  \le (\bar X - \bar Y)-L).$$
So that a 95% CI for $\delta$ would be of the form
$((\bar X - \bar Y)-U,\; (\bar X - \bar Y)-L).$ 
We use bootstrapping to find approximate values $L^*$ of $L$ and
$U^*$ of $U.$ This involves repeatedly re-sampling from among the $X_i$
to get $\bar X^*$s and from among the $Y_i$ to get $\bar Y^*$s, and
hence a bootstrap distribution of $D^* = \bar X^* - \bar Y^*$s.
We get approximate values $L^*$ and $U^*$ by taking quantiles $0.025$ and
$0.975,$ respectively, of this distribution.
In the program below, we use -re (instead of *) to indicate re-sampling, and
$\hat \delta = D_{obs} = \bar X - \bar Y$ is temporarily a proxy for
the unknown $\delta.$
x = 1:3;  y = 4:6;  d.obs=mean(x)-mean(y);  d.obs
[1] -3
set.seed(830)
d.re = replicate(2000, 
       mean(sample(x,3,rep=T)) - mean(sample(y,3,rep=T)) - d.obs)
UL = quantile(d.re, c(.975,.025))
d.obs - UL
    97.5%      2.5% 
-4.333333 -1.666667 

In the final step $D_{obs}$ returns to its original role as $\hat \delta.$
So a 95% nonparametric bootstrap CI for $\delta$ is $(-4.33, -1.67).$
By contrast a (questionable) 95% t interval for these data from a Welch two-sample test is $(-5.27, -0.73).$
t.test(x, y)$conf.int
[1] -5.2669579 -0.7330421
 attr(,"conf.level")
 [1] 0.95

With such small sample sizes, a 2-sample Wilcoxon 95% CI for the 'shift' is not available;
the 90% CI is  $(-5, -1).$
