mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-08-14 22:09:29 +02:00
Replace Karma + Jasmine with Jest
This commit is contained in:
34
__mocks__/d3.js
vendored
Normal file
34
__mocks__/d3.js
vendored
Normal file
@@ -0,0 +1,34 @@
|
||||
let NewD3 = function () {
|
||||
return {
|
||||
append: function () {
|
||||
return NewD3()
|
||||
},
|
||||
attr: function () {
|
||||
return this
|
||||
},
|
||||
style: function () {
|
||||
return this
|
||||
},
|
||||
text: function () {
|
||||
return this
|
||||
},
|
||||
0: {
|
||||
0: {
|
||||
getBBox: function () {
|
||||
return {
|
||||
height: 10,
|
||||
width: 20
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
export const select = function () {
|
||||
return new NewD3()
|
||||
}
|
||||
|
||||
export const selectAll = function () {
|
||||
return new NewD3()
|
||||
}
|
Reference in New Issue
Block a user