Get help with testing, discuss unit testing strategies etc.


Post by nuridesengin »

I've created a Test class and has a method which doing clicks on admindashboard's navigation menu and facing with this error. The thing is mostly test became passed but sometimes it gives this error mostly on this step/item or sometimes on other step/item after this WARN!

When I've debug it got me to siesta-all. What could be the reason with that one?
WARN: Your component query: ">> treelistitem[_text=FooBar]" returned more than 1 component
Test threw an exception
TypeError: Cannot read property 'getEntity' of null
    at line 711, character 41, of https://localhost:1841/ext/packages/core/src/data/Session.js?_dc=1515584150560
    at line 482, character 14, of https://localhost:1841/ext/packages/core/src/data/Session.js?_dc=1515584150560
    at line 1065, character 29, of https://localhost:1841/ext/packages/core/src/data/Session.js?_dc=1515584150560
    at line 850, character 28, of https://localhost:1841/ext/packages/core/src/data/reader/Reader.js?_dc=1515584150560
    at line 797, character 33, of https://localhost:1841/ext/packages/core/src/data/reader/Reader.js?_dc=1515584150560
    at line 1387, character 32, of https://localhost:1841/ext/packages/core/src/class/Base.js?_dc=1515584150559
    at line 312, character 21, of https://localhost:1841/ext/packages/core/src/data/reader/Json.js?_dc=1515584150560
    at line 704, character 30, of https://localhost:1841/ext/packages/core/src/data/reader/Reader.js?_dc=1515584150560
    at line 593, character 33, of https://localhost:1841/ext/packages/core/src/data/reader/Reader.js?_dc=1515584150560
    at line 306, character 36, of https://localhost:1841/ext/packages/core/src/data/proxy/Server.js?_dc=1515584150560

Post by nickolay »

Sorry, can't guess anything w/o a reproducible test case.

The warning says the query is not unique, which is sometimes intended.

The exception can be anything, try to observe the state in debugger.

Post Reply