mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
fix test, linting
This commit is contained in:
parent
281a6beadd
commit
ad12dd46f4
@ -145,9 +145,9 @@ export default {
|
|||||||
},
|
},
|
||||||
async updateGdt() {
|
async updateGdt() {
|
||||||
const result2 = await communityAPI.transactionsgdt(this.$store.state.sessionId)
|
const result2 = await communityAPI.transactionsgdt(this.$store.state.sessionId)
|
||||||
console.log(' communityAPI.transactionsgdt')
|
// console.log(' communityAPI.transactionsgdt')
|
||||||
console.log(result2.result)
|
// console.log(result2.result)
|
||||||
console.log(result2.result.data.gdtEntries)
|
// console.log(result2.result.data.gdtEntries)
|
||||||
this.GdtBalance = Number(result2.result.data.gdtSum)
|
this.GdtBalance = Number(result2.result.data.gdtSum)
|
||||||
this.transactionsGdt = result2.result.data.gdtEntries
|
this.transactionsGdt = result2.result.data.gdtEntries
|
||||||
this.transactionGdtCount = result2.result.data.count
|
this.transactionGdtCount = result2.result.data.count
|
||||||
|
|||||||
@ -22,8 +22,6 @@
|
|||||||
<small>{{ $d($moment(date), 'long') }} {{ $i18n.locale === 'de' ? 'Uhr' : '' }}</small>
|
<small>{{ $d($moment(date), 'long') }} {{ $i18n.locale === 'de' ? 'Uhr' : '' }}</small>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<div v-if="gdt_entry_type_id === 7">{{ amount }} GDT * {{ factor }} = {{ gdt }}</div>
|
<div v-if="gdt_entry_type_id === 7">{{ amount }} GDT * {{ factor }} = {{ gdt }}</div>
|
||||||
<div v-else>{{ amount }} € ⊢ {{ gdt }} GDT</div>
|
<div v-else>{{ amount }} € ⊢ {{ gdt }} GDT</div>
|
||||||
<small>
|
<small>
|
||||||
|
|||||||
@ -1,8 +1,18 @@
|
|||||||
import { shallowMount } from '@vue/test-utils'
|
import { mount } from '@vue/test-utils'
|
||||||
import UserProfileTransactionList from './UserProfileTransactionList'
|
import UserProfileTransactionList from './UserProfileTransactionList'
|
||||||
|
|
||||||
const localVue = global.localVue
|
const localVue = global.localVue
|
||||||
|
|
||||||
|
const mutationObserverMock = jest.fn(function MutationObserver(callback) {
|
||||||
|
this.observe = jest.fn()
|
||||||
|
this.disconnect = jest.fn()
|
||||||
|
this.trigger = (mockedMutationsList) => {
|
||||||
|
callback(mockedMutationsList, this)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
global.MutationObserver = mutationObserverMock
|
||||||
|
|
||||||
describe('UserProfileTransactionList', () => {
|
describe('UserProfileTransactionList', () => {
|
||||||
let wrapper
|
let wrapper
|
||||||
|
|
||||||
@ -12,7 +22,7 @@ describe('UserProfileTransactionList', () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const Wrapper = () => {
|
const Wrapper = () => {
|
||||||
return shallowMount(UserProfileTransactionList, { localVue, mocks })
|
return mount(UserProfileTransactionList, { localVue, mocks })
|
||||||
}
|
}
|
||||||
|
|
||||||
describe('mount', () => {
|
describe('mount', () => {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user