Intermittent test results with trivial yjs example from the


I’m just getting started with yjs and running into issues trying to write a Jasmin test with yjs code inspired in the

const doc = new Y.Doc()
const data = doc.getMap("data")
data.set("generator", "")
data.set("generator", "something")

const update = Y.encodeStateAsUpdate(doc)

const doc2 = new Y.Doc()
Y.applyUpdate(doc2, update)

const data2 = doc2.getMap("data")

The second expect call fails intermittently saying that the data2.get("generator") returns undefined instead of returning "something".

Any ideas?

Huh, it just started working. I must have had some kind of bad cached test or something. :man_shrugging: