You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In an excel custom functions add in, I have to add a CustomFunctions.Error function to the global scope before running tests. I am using the following code (which I am not suggesting is sufficient to cover the use cases for the broad range of users) which gives a brief outline of another module which could be useful if added to the Office-Addin-Mock package:
describe("myFunction",function(){global.CustomFunctions=CustomFunctions;it("throws an error when the string argument is empty",function(){expect(()=>myFunction("",[[["a"]]])).to.throw(/require/i);'''
The text was updated successfully, but these errors were encountered:
The office-addin-mock package does not provide one of the available enums in the Office namespace.
This means that each one you use in code has to be mocked before being able to run tests. Silly.
In an excel custom functions add in, I have to add a CustomFunctions.Error function to the global scope before running tests. I am using the following code (which I am not suggesting is sufficient to cover the use cases for the broad range of users) which gives a brief outline of another module which could be useful if added to the Office-Addin-Mock package:
and it is used something like (mocha/chai):
The text was updated successfully, but these errors were encountered: