test fixed
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
cbaba8a075
commit
3424fabd5b
|
@ -3,4 +3,6 @@ DELETE FROM `salix`.`ACL` WHERE id = 188;
|
|||
UPDATE `salix`.`ACL` tdms SET tdms.accessType = '*'
|
||||
WHERE tdms.id = 165;
|
||||
INSERT INTO salix.ACL (model, principalId, property, accessType)
|
||||
VALUES ('InvoiceInTax','administrative', '*', '*');
|
||||
VALUES ('InvoiceInTax','administrative', '*', '*');
|
||||
INSERT INTO salix.ACL (model, principalId, property, accessType)
|
||||
VALUES ('InvoiceInLog','administrative', '*', 'READ');
|
|
@ -22,20 +22,18 @@ describe('InvoiceIn', () => {
|
|||
controller.invoiceIn = {id: 1};
|
||||
}));
|
||||
|
||||
describe('setTaxRate() setter', () => {
|
||||
describe('taxRate()', () => {
|
||||
it('should set tax rate with the Sage tax type value', () => {
|
||||
const taxTypeSage = {
|
||||
const taxRateSelection = {
|
||||
rate: 21
|
||||
};
|
||||
$scope.taxTypeSage = {};
|
||||
$scope.taxTypeSage.selection = taxTypeSage;
|
||||
const invoiceInTax = {
|
||||
taxableBase: 200
|
||||
};
|
||||
|
||||
$scope.taxableBase = {};
|
||||
$scope.taxableBase.value = 200;
|
||||
const taxRate = controller.taxRate(invoiceInTax, taxRateSelection);
|
||||
|
||||
controller.taxRateSelection = 0;
|
||||
|
||||
expect(controller.taxRate).toEqual(42);
|
||||
expect(taxRate).toEqual(42);
|
||||
});
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in New Issue