I wear diapers full time and have worn diapers full time for over 5 years now and no longer use the toilet.
Since I wear diapers all the time now and go everywhere in diapers and yes I've gone hiking while wearing diapers and it's never been a problem.
I would recommend adding some baby powder to your diaper and add some diaper rash cream to around your leg areas to prevent any possible chafing as your legs move back and forth against the diaper.
I wear some thick adult disposable diapers from ABU Diapers when hiking and haven't gotten a rash or chafing when hiking.
Hiking in diapers is very fun and when you're wearing diapers when on your hike you can go pee or poop when needed without having to find a place to use the bathroom.
Diapers are my bathroom all the time now and I never use a toilet at all.