chisq.test and wilcox.test don't concord with my graphs and observations? I want to know if a factor variable have an incidence on another variable (dura). For example :
dat <- data.frame(cond = factor(rep(c("yes", "no", ""), each = 15)), 
                  dura = abs(rnorm(45)),
                  ms = rnorm(45))



df1 <- filter(dat, cond == "yes")
df2 <- filter(dat, cond == "no")

wilcox.test(df1$dura, df2$dura)

t <- table(dat$cond, dat$dura)
t[-1, ]
chisq.test(t)

I want to know if "dura" depends of "cond", here I can see that dura don't depend of the condition.
In my problem, the dura density looks like :

We could see the dura don't depend of factor, but when I do wilcoxon, I have :
wilcox.test(as.numeric(x1$dura), as.numeric(x2$dura))

Wilcoxon rank sum test with continuity correction

 data:  as.numeric(x1$dura) and as.numeric(x2$dura)
W = 7546443, p-value < 0.00000000000000022
alternative hypothesis: true location shift is not equal to 0

Which means that we reject H0 ...
Thank you

x1 correspond to the "oui" factor and x2 correspond to the "non" factor. x1 get 5200 observation and x2 get 3800 observations.


 A: I see no reason whatever from the information supplied to think that the Wilcoxon test should return a high p-value.
Your initial simulation uses a different sample size and different distribution to your actual data (and is set so the null is true, which is unlikely to be the case with your data). It is in no way informative about what should happen with your data.
You didn't give any real way of judging whether the samples are different enough to be told apart from random variation. You don't even state a sample size for your actual data, but from the size of $W$ in the output I'm guessing it's pretty big, probably in the ballpark of several thousand in each sample.
Just because distributions look similar is no basis on which to guess whether they're different enough to be picked up by a statistical test. You seem to be confusing statistical significance (can we tell they're not random samples from the same population) with practical significance (are they different enough to matter to us). With large samples you can easily detect very small differences, ones you may not readily see visually.
Here's an example that I generated where the data ($n_a=3000, n_b=3000$) are from Pareto distributions with slightly different parameters, along with what their logs look like:

Their log-scale densities look very similar. However, with a Wilcoxon test the p-value is about $1.6\times 10^{-9}$.
There's no mistake there, that's exactly what is supposed to happen.

If all your data are strictly positive, I suggest you look at the logs of your data, which might make visual comparison easier; the log-data will have the same $W$ statistic.
If "dura" are durations it might even make sense to look at reciprocals of the data (which would then be speeds or rates).
Besides such displays, summary statistics (means and sds, quartiles and median, min and max, and especially sample size) on the log or inverse scale would definitely help assess whether it would make sense for the p-value to be low, but I see no indication that anything is amiss.
