diff --git a/docs/make.jl b/docs/make.jl index 6039ae20c..078cc6d70 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -103,7 +103,7 @@ spinw_sources = filter(endswith(".jl"), readdir(pkgdir(Sunny, "examples", "spinw spinw_names = [splitext(basename(src))[1] for src in spinw_sources] spinw_mds = build_examples(spinw_sources, joinpath("examples", "spinw")) -# contributed_mds = isdraft ? [] : prepare_contributed() +contributed_mds = isdraft ? [] : prepare_contributed() # Build docs as HTML, including the `examples/name.md` markdown built above @@ -114,8 +114,8 @@ Documenter.makedocs(; "index.md", "Examples" => [ example_mds..., - # "Contributed" => contributed_mds, "SpinW ports" => spinw_mds, + "Contributed" => contributed_mds, ], "Guides" => [ "structure-factor.md", diff --git a/test/test_lswt.jl b/test/test_lswt.jl index 8a2eed95f..4a2f1f06d 100644 --- a/test/test_lswt.jl +++ b/test/test_lswt.jl @@ -459,13 +459,13 @@ end @testitem "Invariance to spin rotation" begin - using LinearAlgebra + using LinearAlgebra, Random function build_system(R, D1, D2, J, K1, K2, h, g) latvecs = lattice_vectors(1, 1, 1, 92, 93, 94) cryst = Crystal(latvecs, [[0,0,0], [0.4,0,0]]; types=["A", "B"]) infos = [1 => Moment(s=1, g=2), 2 => Moment(s=2, g=R*g*R')] - sys = System(cryst, infos, :dipole) + sys = System(cryst, infos, :dipole; seed=101) set_onsite_coupling!(sys, S -> S'*R*(D1+D1')*R'*S, 1) set_onsite_coupling!(sys, S -> S'*R*(D2+D2')*R'*S, 2) @@ -479,13 +479,14 @@ end return sys end - g = randn(3,3) + Random.seed!(101) + g = randn(3,3) D1 = randn(3,3) D2 = randn(3,3) - J = randn(3,3) + J = randn(3,3) K1 = randn(3,3) K2 = randn(3,3) - h = randn(3) + h = randn(3) R1 = Sunny.Mat3(I) R2 = Sunny.axis_angle_to_matrix(randn(3), 0.46) sys1 = build_system(R1, D1, D2, J, K1, K2, h, g)