Hi,
I agree with what Irish said. It depends.
Are you joining two lines; tying to terminal tackle; tying to the hook.
I have snelled hooks with 100 lb. test mono. I snell almost all of my hooks. If I cannot snell them, I use a crimp.
I use a uni knot for almost everything else, even joining two lines.
Another useful knot is a surgeons knot. You can tie a strong loop with any test with that.
The key to tying the knot is to wet it so that you can draw it tight! Remember that knots do not fail until they slip (the heat from the friction is a disaster).
So, with 40 lb. flouro or mono, snelling to the hook and using a uni knot for terminal tackle would be my advice. Uni knots are fast to tie, even in the dark. The yare also easy to pull tight.
Good luck,
Capt. Ed