Started store tests

This commit is contained in:
Jason Wheeler 2022-10-10 16:20:26 -04:00
parent 5cbd6c4e46
commit 6d5accd06f

21
src/store/store.spec.js Normal file
View file

@ -0,0 +1,21 @@
import { useMainStore } from "./"
import { createApp } from 'vue';
import { createPinia } from "pinia";
import App from '@/App.vue';
describe("Store", () => {
let store = null;
beforeAll(() => {
const vueApp = createApp(App);
const pinia = createPinia();
vueApp.use(pinia);
store = useMainStore();
})
it("Should Store Vehicle Year", () => {
let testYear = "2001";
store.updateVehicleYear(testYear);
expect(store.order.vehicle.year).toEqual(testYear);
});
});