Throw EdgeExistsException.
auto g1 = Graph!int([1, 2]); alias CS = g1.ConflictStrategy; g1 ~= g1.edge(1, 2); assertThrown!EdgeExistsException(g1.add!(CS.error)(g1.edge(1, 2)));
See Implementation
Throw EdgeExistsException.