I am using vue-test-utils and jest in order to test my code. My test run without any problem except if it pass through the code below
$nuxt.$store.commit("device/saveState", {
id: this.$.id,
key: this.$.ac_key,
power: this.$.ac_power,
mode: this.$.ac_mode,
temp: this.$.ac_temp,
wind: this.$.ac_wind
})
and it will give me this error
[Vue warn]: Error in created hook: "ReferenceError: $nuxt is not defined"