So, for what it's worth if you're captured and stripped of your gear it's as simple as using detect magic on your tattoos (which is likely since it's a cantrip) to determine if they are magical. And if they find it is magical they're likely going to dispel/erase/destroy them.
In my mind it's not a viable plan.
A better plan is to convince your spellcaster to hide a backup spellbook in secluded grimoire and use secret chest once they're able.
Off topic, but I felt like I had to share
A dm let me do a similar thing in a 3.5 game as a warforged, and I had it on my arms,legs, chest, palms, etc. I don't know if it was by the rules, but we had previously established that as a warforged I would light up on a detect magic search, so when the exact event you described came about, I got away with it.