You can check if it respond_to?
certain methods that come along with audited gem.
like
User.respond_to?(:audited)
# or
User.respond_to?(:audits)
Also you could use auditing_enabled
option from the readme.
User.auditing_enabled
This returns in default true when audited is there.
The same for associated audits. Just build a data structure for you relation and check of the audits are equal your expected results.
Take this example from the audited readme for example:
company = Company.create!(name: "Collective Idea")
user = company.users.create!(name: "Steve")
user.update_attribute!(name: "Steve Richert")
user.audits.last.associated # => #<Company name: "Collective Idea">
company.associated_audits.last.auditable # => #<User name: "Steve Richert">
There you can then easily check if the associated audits look like you want it.