hexsha stringlengths 40 40 | size int64 38 969k | ext stringclasses 1
value | lang stringclasses 1
value | max_stars_repo_path stringlengths 4 106 | max_stars_repo_name stringlengths 8 104 | max_stars_repo_head_hexsha stringlengths 40 40 | max_stars_repo_licenses listlengths 1 4 | max_stars_count int64 1 38.8k ⌀ | max_stars_repo_stars_event_min_datetime stringlengths 24 24 ⌀ | max_stars_repo_stars_event_max_datetime stringlengths 24 24 ⌀ | max_issues_repo_path stringlengths 4 106 | max_issues_repo_name stringlengths 8 104 | max_issues_repo_head_hexsha stringlengths 40 40 | max_issues_repo_licenses listlengths 1 4 | max_issues_count int64 1 53.3k ⌀ | max_issues_repo_issues_event_min_datetime stringlengths 24 24 ⌀ | max_issues_repo_issues_event_max_datetime stringlengths 24 24 ⌀ | max_forks_repo_path stringlengths 4 106 | max_forks_repo_name stringlengths 8 104 | max_forks_repo_head_hexsha stringlengths 40 40 | max_forks_repo_licenses listlengths 1 4 | max_forks_count int64 1 6.24k ⌀ | max_forks_repo_forks_event_min_datetime stringlengths 24 24 ⌀ | max_forks_repo_forks_event_max_datetime stringlengths 24 24 ⌀ | content stringlengths 38 969k | avg_line_length float64 6.33 6.5k | max_line_length int64 15 269k | alphanum_fraction float64 0.18 0.91 | test_functions listlengths 1 212 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
79f55988393ccba161a4fd4ef57524243e191ea0 | 2,223 | jl | Julia | test/benefit_cap_tests.jl | grahamstark/ScottishTaxBenefitModel | 894f37c6debec271a0e4e4f09aa7b9599423d563 | [
"MIT"
] | null | null | null | test/benefit_cap_tests.jl | grahamstark/ScottishTaxBenefitModel | 894f37c6debec271a0e4e4f09aa7b9599423d563 | [
"MIT"
] | null | null | null | test/benefit_cap_tests.jl | grahamstark/ScottishTaxBenefitModel | 894f37c6debec271a0e4e4f09aa7b9599423d563 | [
"MIT"
] | null | null | null | using Test
using Dates
using ScottishTaxBenefitModel
using .ModelHousehold:
Household,
Person,
People_Dict,
default_bu_allocation,
get_benefit_units,
get_head,
get_spouse,
is_single,
pers_is_carer,
pers_is_disabled,
search
using .Definitions
using .BenefitCap... | 25.848837 | 157 | 0.548358 | [
"@testset \"Benefit Cap Shakedown\" begin\n examples = get_all_examples()\n hbs = collect(100:100:1000)\n for (hht,hh) in examples \n bus = get_benefit_units( hh )\n intermed = make_intermediate( \n hh,\n sys.hours_limits,\n sys.age_limits,\n sys.ch... |
79f75cde4f0ab0ba156978831671560c87661106 | 1,684 | jl | Julia | test/fourier_transforms.jl | jaemolihm/DFTK.jl | 5d2bb8fcee108732d2959808d040718999b9a22b | [
"MIT"
] | 243 | 2019-11-26T19:51:02.000Z | 2022-03-27T08:29:35.000Z | test/fourier_transforms.jl | jaemolihm/DFTK.jl | 5d2bb8fcee108732d2959808d040718999b9a22b | [
"MIT"
] | 372 | 2019-11-10T09:28:34.000Z | 2022-03-31T19:32:08.000Z | test/fourier_transforms.jl | jaemolihm/DFTK.jl | 5d2bb8fcee108732d2959808d040718999b9a22b | [
"MIT"
] | 53 | 2020-03-13T18:23:21.000Z | 2022-03-27T08:29:38.000Z | using Test
using DFTK: PlaneWaveBasis, G_to_r!, r_to_G!, G_to_r, r_to_G
include("testcases.jl")
@testset "FFT and IFFT are an identity" begin
Ecut = 4.0 # Hartree
fft_size = [8, 8, 8]
model = Model(silicon.lattice, n_electrons=silicon.n_electrons)
pw = PlaneWaveBasis(model, Ecut, silicon.kcoords, sil... | 33.68 | 89 | 0.612233 | [
"@testset \"FFT and IFFT are an identity\" begin\n Ecut = 4.0 # Hartree\n fft_size = [8, 8, 8]\n model = Model(silicon.lattice, n_electrons=silicon.n_electrons)\n pw = PlaneWaveBasis(model, Ecut, silicon.kcoords, silicon.ksymops; fft_size=fft_size)\n\n @testset \"Transformation on the cubic basis se... |
79f7f166c63d23f984961edea2a5cf492e3f5a34 | 2,409 | jl | Julia | test/UserNamespaces.jl | staticfloat/Sandbox.jl | 44ca510f25f17fb9e4cf15fc6f6eeb7c1ac3ec31 | [
"MIT"
] | 19 | 2021-01-19T23:25:37.000Z | 2022-03-21T00:34:16.000Z | test/UserNamespaces.jl | staticfloat/Sandbox.jl | 44ca510f25f17fb9e4cf15fc6f6eeb7c1ac3ec31 | [
"MIT"
] | 74 | 2021-01-19T23:14:36.000Z | 2022-03-31T06:29:05.000Z | test/UserNamespaces.jl | staticfloat/Sandbox.jl | 44ca510f25f17fb9e4cf15fc6f6eeb7c1ac3ec31 | [
"MIT"
] | 8 | 2021-01-19T19:05:43.000Z | 2022-03-01T01:02:28.000Z | using Test, Sandbox
if Sys.islinux()
@test isa(Sandbox.get_kernel_version(), VersionNumber)
@test Sandbox.check_kernel_version()
end
if executor_available(UnprivilegedUserNamespacesExecutor)
@testset "UnprivilegedUserNamespacesExecutor" begin
@test_logs (:info, "Testing Unprivileged User Namespace... | 42.263158 | 123 | 0.651308 | [
"@testset \"UnprivilegedUserNamespacesExecutor\" begin\n @test_logs (:info, \"Testing Unprivileged User Namespaces Executor (read-only, read-write)\") begin\n with_executor(UnprivilegedUserNamespacesExecutor) do exe\n @test probe_executor(exe; test_read_only_map=true, test_read_writ... |
79f884b5f79a01468202de63411ec6665e34ea87 | 1,176 | jl | Julia | test/quantloguniform.jl | lhnguyen-vn/TreeParzen.jl | d6b4181a45167663e8844330220f0c62c715c75f | [
"BSD-3-Clause"
] | 23 | 2020-05-06T09:06:20.000Z | 2021-08-12T22:41:16.000Z | test/quantloguniform.jl | lhnguyen-vn/TreeParzen.jl | d6b4181a45167663e8844330220f0c62c715c75f | [
"BSD-3-Clause"
] | 47 | 2020-05-15T14:29:13.000Z | 2021-10-04T15:24:44.000Z | test/quantloguniform.jl | lhnguyen-vn/TreeParzen.jl | d6b4181a45167663e8844330220f0c62c715c75f | [
"BSD-3-Clause"
] | 4 | 2020-09-11T03:47:54.000Z | 2021-09-21T18:42:50.000Z | """
Based on
https://hyperopt.github.io/hyperopt/
"""
module TestQuantLogUniform
using Test
using TreeParzen
@testset "quantised log uniform" begin
qlu = HP.QuantLogUniform(:qlu, log(1.01), log(20.0), 2.0)
N = 10_000
qlu_samples = [TreeParzen.Resolve.node(qlu, TreeParzen.Trials.ValsDict()) for i in 1:N]... | 30.947368 | 91 | 0.694728 | [
"@testset \"quantised log uniform\" begin\n\n qlu = HP.QuantLogUniform(:qlu, log(1.01), log(20.0), 2.0)\n N = 10_000\n\n qlu_samples = [TreeParzen.Resolve.node(qlu, TreeParzen.Trials.ValsDict()) for i in 1:N]\n\n @test all(qlu_samples .% 2 .== 0)\n @test minimum(qlu_samples) == 2\n @test maximum(q... |
79fa9eae522b6e884668e0c92c5118f404262540 | 2,406 | jl | Julia | test/Bridges/Objective/functionize.jl | jd-foster/MathOptInterface.jl | f5cc48179a7b41908000259566fe1d5a1f59b45a | [
"MIT"
] | 132 | 2020-06-20T00:45:49.000Z | 2022-03-28T22:06:34.000Z | test/Bridges/Objective/functionize.jl | jd-foster/MathOptInterface.jl | f5cc48179a7b41908000259566fe1d5a1f59b45a | [
"MIT"
] | 460 | 2020-06-08T14:12:55.000Z | 2022-03-31T19:03:39.000Z | test/Bridges/Objective/functionize.jl | guilhermebodin/MathOptInterface.jl | 6b50fa0f9e31ef97a06facaad60af7d0b6ae3d2a | [
"MIT"
] | 28 | 2020-06-08T01:45:29.000Z | 2022-03-23T10:36:25.000Z | module TestObjectiveFunctionize
using Test
using MathOptInterface
const MOI = MathOptInterface
function runtests()
for name in names(@__MODULE__; all = true)
if startswith("$(name)", "test_")
@testset "$(name)" begin
getfield(@__MODULE__, name)()
end
end
... | 32.958904 | 78 | 0.668745 | [
"@testset \"$(name)\" begin\n getfield(@__MODULE__, name)()\n end"
] |
0301c73d216d48c0ee31baea2ddcc845a0785031 | 10,112 | jl | Julia | test/shadowing.jl | stjordanis/DiffEqSensitivity.jl | 8f8753b9fda0300b76a68a22b7f86ee0b7eda635 | [
"MIT"
] | null | null | null | test/shadowing.jl | stjordanis/DiffEqSensitivity.jl | 8f8753b9fda0300b76a68a22b7f86ee0b7eda635 | [
"MIT"
] | null | null | null | test/shadowing.jl | stjordanis/DiffEqSensitivity.jl | 8f8753b9fda0300b76a68a22b7f86ee0b7eda635 | [
"MIT"
] | null | null | null | using Random; Random.seed!(1234)
using OrdinaryDiffEq
using Statistics
using ForwardDiff, Calculus
using DiffEqSensitivity
using Test
using Zygote
@testset "LSS" begin
@testset "Lorentz single parameter" begin
function lorenz!(du,u,p,t)
du[1] = 10*(u[2]-u[1])
du[2] = u[1]*(p[1]-u[3]) - u[2]
du[... | 35.356643 | 137 | 0.668018 | [
"@testset \"LSS\" begin\n @testset \"Lorentz single parameter\" begin\n function lorenz!(du,u,p,t)\n du[1] = 10*(u[2]-u[1])\n du[2] = u[1]*(p[1]-u[3]) - u[2]\n du[3] = u[1]*u[2] - (8//3)*u[3]\n end\n\n p = [28.0]\n tspan_init = (0.0,30.0)\n tspan_attractor = (30.0,50.0)\n u0 = rand... |
030249739db6f3e76dd9bf9665ef7b92b870cf6f | 111 | jl | Julia | test/runtests.jl | tk3369/BinaryTraitsTestX | 6c64d068f827c2a3f68f78df4fcb21ef36b51503 | [
"MIT"
] | 1 | 2021-02-18T03:12:56.000Z | 2021-02-18T03:12:56.000Z | test/runtests.jl | tk3369/BinaryTraitsTestX | 6c64d068f827c2a3f68f78df4fcb21ef36b51503 | [
"MIT"
] | null | null | null | test/runtests.jl | tk3369/BinaryTraitsTestX | 6c64d068f827c2a3f68f78df4fcb21ef36b51503 | [
"MIT"
] | 1 | 2021-02-18T03:12:59.000Z | 2021-02-18T03:12:59.000Z | using BinaryTraitsTestX
using Test
@testset "BinaryTraitsTestX.jl" begin
# Write your own tests here.
end
| 15.857143 | 37 | 0.774775 | [
"@testset \"BinaryTraitsTestX.jl\" begin\n # Write your own tests here.\nend"
] |
03031cac422e6126d001748a6b995b9e4dafcfea | 311 | jl | Julia | test/runtests.jl | mcfefa/GeckoScreen.jl | babbd982e84af60bac13ad95a05589eb6db9ade4 | [
"MIT"
] | null | null | null | test/runtests.jl | mcfefa/GeckoScreen.jl | babbd982e84af60bac13ad95a05589eb6db9ade4 | [
"MIT"
] | null | null | null | test/runtests.jl | mcfefa/GeckoScreen.jl | babbd982e84af60bac13ad95a05589eb6db9ade4 | [
"MIT"
] | null | null | null | using GeckoScreen
using Test
using DataFrames
using CSV
using Query
testcsv(path::AbstractString; kwargs...) = CSV.read(path, DataFrame; kwargs...)
@testset "GeckoScreen.jl" begin
# Write your tests here.
gmap = readGeCKOlibrary()
first(gmap,6)
#@test size(readGeCKOlibrary, 1) == 34
end | 19.4375 | 79 | 0.700965 | [
"@testset \"GeckoScreen.jl\" begin\n # Write your tests here.\n \n gmap = readGeCKOlibrary()\n first(gmap,6)\n #@test size(readGeCKOlibrary, 1) == 34\n\nend"
] |
030353ca3397c884c046b285b7bc07823b6445fd | 5,606 | jl | Julia | test/runtests.jl | cmcaine/BrokenRecord.jl | 5ecdd561163aa3c9713c9d65adb03281b4bf6798 | [
"MIT"
] | null | null | null | test/runtests.jl | cmcaine/BrokenRecord.jl | 5ecdd561163aa3c9713c9d65adb03281b4bf6798 | [
"MIT"
] | null | null | null | test/runtests.jl | cmcaine/BrokenRecord.jl | 5ecdd561163aa3c9713c9d65adb03281b4bf6798 | [
"MIT"
] | null | null | null | using Test: @test, @testset, @test_logs, @test_throws
using HTTP: HTTP, Form, Request, Response
using JSON: JSON
using BrokenRecord: BrokenRecord, FORMAT, configure!, playback
const BR = BrokenRecord
const url = "https://httpbin.org"
@testset "BrokenRecord.jl" begin
mktempdir() do dir
path = joinpath(di... | 36.640523 | 99 | 0.50767 | [
"@testset \"BrokenRecord.jl\" begin\n mktempdir() do dir\n path = joinpath(dir, \"test1.json\")\n @test playback(() -> 1, path) == 1\n @test isfile(path)\n @test JSON.parsefile(path) == Dict(\"responses\" => [], \"format\" => string(FORMAT))\n\n path = joinpath(dir, \"test2.jso... |
0304c7acf8d9b243c477689d65644157d4081667 | 1,085 | jl | Julia | test/interval_tests/rounding.jl | bocc/IntervalArithmetic.jl | aa781cc5b2d23138d1141519dd652c5e522d5a6e | [
"MIT"
] | 1 | 2021-11-20T04:02:34.000Z | 2021-11-20T04:02:34.000Z | test/interval_tests/rounding.jl | bocc/IntervalArithmetic.jl | aa781cc5b2d23138d1141519dd652c5e522d5a6e | [
"MIT"
] | 1 | 2019-03-28T23:57:24.000Z | 2019-03-28T23:57:24.000Z | test/interval_tests/rounding.jl | bocc/IntervalArithmetic.jl | aa781cc5b2d23138d1141519dd652c5e522d5a6e | [
"MIT"
] | null | null | null | using IntervalArithmetic
using Test
setformat(:full)
# NB: Due to "world age" problems, do *not* wrap everything in another @testset
# The `setrounding` commands must be at top level
setrounding(Interval, :slow)
x = Interval(0.5)
@testset "Tight, slow rounding by changing rounding mode" begin
@test rounding(Int... | 26.463415 | 79 | 0.725346 | [
"@testset \"Tight, slow rounding by changing rounding mode\" begin\n @test rounding(Interval) == :slow\n @test sin(x) == Interval(0.47942553860420295, 0.479425538604203)\nend",
"@testset \"Accurate, fast rounding using prevfloat and nextfloat\" begin\n @test rounding(Interval) == :accurate\n @test sin... |
03075a070889e4623888f19cf6ddeaed8f4b8d60 | 130 | jl | Julia | test/runtests.jl | tkf/PkgOptions.jl | eb282f6f6eab4b985185dd9c4915e11dec743b24 | [
"MIT"
] | 1 | 2019-09-24T00:13:33.000Z | 2019-09-24T00:13:33.000Z | test/runtests.jl | tkf/PkgOptions.jl | eb282f6f6eab4b985185dd9c4915e11dec743b24 | [
"MIT"
] | 1 | 2019-09-11T06:56:57.000Z | 2019-09-11T06:56:57.000Z | test/runtests.jl | tkf/PkgOptions.jl | eb282f6f6eab4b985185dd9c4915e11dec743b24 | [
"MIT"
] | null | null | null | using PkgOptions
using PkgOptionsDemo
using Test
@testset "PkgOptions.jl" begin
@test PkgOptionsDemo.pkgoptions isa Dict
end
| 16.25 | 44 | 0.807692 | [
"@testset \"PkgOptions.jl\" begin\n @test PkgOptionsDemo.pkgoptions isa Dict\nend"
] |
0309730699f1cabb5b69af84ad6a87558f4262c4 | 2,052 | jl | Julia | test/testMultiHypo2Door.jl | UnofficialJuliaMirrorSnapshots/IncrementalInference.jl-904591bb-b899-562f-9e6f-b8df64c7d480 | 454481ee2e1909fbf5d89c16881629e31c8c8eb8 | [
"MIT"
] | null | null | null | test/testMultiHypo2Door.jl | UnofficialJuliaMirrorSnapshots/IncrementalInference.jl-904591bb-b899-562f-9e6f-b8df64c7d480 | 454481ee2e1909fbf5d89c16881629e31c8c8eb8 | [
"MIT"
] | null | null | null | test/testMultiHypo2Door.jl | UnofficialJuliaMirrorSnapshots/IncrementalInference.jl-904591bb-b899-562f-9e6f-b8df64c7d480 | 454481ee2e1909fbf5d89c16881629e31c8c8eb8 | [
"MIT"
] | null | null | null | # load requried packages
using IncrementalInference
using Test
## parameters
lm_prior_noise = 0.01
meas_noise = 0.25
odom_noise = 0.1
n_samples = 200
# initialize mean landmark locations
l0 = 0.0
l1 = 10.0
l2 = 40.0
# "Ground-truth" robot poses
x0 = 0.0
x1 = 10.0
x2 = 20.0
x3 = 40.0
@testset "2door basic binary ... | 23.05618 | 108 | 0.694932 | [
"@testset \"2door basic binary multihypothesis tests...\" begin\n\n## Initialize empty factor graph\nfg = initfg()\nfg.solverParams.N = n_samples\n# Place strong prior on locations of three \"doors\"\naddVariable!(fg, Symbol(\"l0\"), ContinuousScalar, N=n_samples)\naddFactor!(fg, [:l0], Prior(Normal(l0, lm_prior_no... |
030b0229d140f636530f62eb5900f7786d655559 | 29,963 | jl | Julia | stdlib/LinearAlgebra/test/triangular.jl | llarsen71/julia | 2a36f83ce9bdfd17c572472f60b830aedcf181f0 | [
"Zlib"
] | 1 | 2020-09-26T21:17:10.000Z | 2020-09-26T21:17:10.000Z | stdlib/LinearAlgebra/test/triangular.jl | llarsen71/julia | 2a36f83ce9bdfd17c572472f60b830aedcf181f0 | [
"Zlib"
] | 1 | 2015-05-09T21:58:12.000Z | 2015-05-27T14:58:28.000Z | stdlib/LinearAlgebra/test/triangular.jl | llarsen71/julia | 2a36f83ce9bdfd17c572472f60b830aedcf181f0 | [
"Zlib"
] | null | null | null | # This file is a part of Julia. License is MIT: https://julialang.org/license
module TestTriangular
debug = false
using Test, LinearAlgebra, SparseArrays, Random
using LinearAlgebra: BlasFloat, errorbounds, full!, naivesub!, transpose!,
UnitUpperTriangular, UnitLowerTriangular,
mul!, rdiv!, rmul!, lmul!
debu... | 45.398485 | 361 | 0.541201 | [
"@testset \"similar should preserve underlying storage type\" begin\n local m, n = 4, 3\n sparsemat = sprand(m, m, 0.5)\n for TriType in (UpperTriangular, LowerTriangular, UnitUpperTriangular, UnitLowerTriangular)\n trisparsemat = TriType(sparsemat)\n @test isa(similar(trisparsemat), typeof(t... |
030befb30aaae662500ac985bc4f6e26205035f9 | 86,616 | jl | Julia | test/ranges.jl | bastiencaillot/julia | 1b8cf40dc0936d657222fe44a4993a580d63098e | [
"MIT"
] | 1 | 2019-06-06T07:05:16.000Z | 2019-06-06T07:05:16.000Z | test/ranges.jl | bastiencaillot/julia | 1b8cf40dc0936d657222fe44a4993a580d63098e | [
"MIT"
] | 1 | 2021-10-15T00:36:25.000Z | 2021-10-15T01:26:50.000Z | test/ranges.jl | bastiencaillot/julia | 1b8cf40dc0936d657222fe44a4993a580d63098e | [
"MIT"
] | 1 | 2021-10-20T06:41:57.000Z | 2021-10-20T06:41:57.000Z | # This file is a part of Julia. License is MIT: https://julialang.org/license
using Base.Checked: checked_length
@testset "range construction" begin
@test_throws ArgumentError range(start=1, step=1, stop=2, length=10)
@test_throws ArgumentError range(start=1, step=1, stop=10, length=11)
r = 3.0:2:11
... | 39.210502 | 177 | 0.560093 | [
"@testset \"range construction\" begin\n @test_throws ArgumentError range(start=1, step=1, stop=2, length=10)\n @test_throws ArgumentError range(start=1, step=1, stop=10, length=11)\n\n r = 3.0:2:11\n @test r == range(start=first(r), step=step(r), stop=last(r) )\n @test r == range(st... |
030e4a27625f6b599ea22e63920936150a5f0e1f | 34,324 | jl | Julia | stdlib/LinearAlgebra/test/triangular.jl | matthias314/julia | 6dfa6902697ccfe390e10fad0083ad047560dc5a | [
"Zlib"
] | 3 | 2021-08-28T17:47:56.000Z | 2021-08-29T06:55:15.000Z | stdlib/LinearAlgebra/test/triangular.jl | zhuangchaoxi/julia | c593eeb9326693febfb84ea054fc1458c2e99d99 | [
"Zlib"
] | 3 | 2016-04-15T13:46:09.000Z | 2019-08-31T15:41:12.000Z | stdlib/LinearAlgebra/test/triangular.jl | zhuangchaoxi/julia | c593eeb9326693febfb84ea054fc1458c2e99d99 | [
"Zlib"
] | 1 | 2016-02-04T17:34:04.000Z | 2016-02-04T17:34:04.000Z | # This file is a part of Julia. License is MIT: https://julialang.org/license
module TestTriangular
debug = false
using Test, LinearAlgebra, SparseArrays, Random
using LinearAlgebra: BlasFloat, errorbounds, full!, naivesub!, transpose!,
UnitUpperTriangular, UnitLowerTriangular,
mul!, rdiv!, rmul!, lmul!
debu... | 45.282322 | 361 | 0.540963 | [
"@testset \"check matrix logarithm type-inferrable\" for elty in (Float32,Float64,ComplexF32,ComplexF64)\n A = UpperTriangular(exp(triu(randn(elty, n, n))))\n @inferred Union{typeof(A),typeof(complex(A))} log(A)\n @test exp(Matrix(log(A))) ≈ A\n if elty <: Real\n @test typeof(log(A)) <: UpperTria... |
031044a1130eeb5108c44cd332a44c4a952370a3 | 1,208 | jl | Julia | test/compute_shifts.jl | andreasnoack/ArnoldiMethod.jl | d44bac4022e5e39f9fa80f6398091c41180ec5a8 | [
"MIT"
] | 41 | 2018-08-28T14:04:26.000Z | 2021-07-29T02:18:47.000Z | test/compute_shifts.jl | andreasnoack/ArnoldiMethod.jl | d44bac4022e5e39f9fa80f6398091c41180ec5a8 | [
"MIT"
] | 37 | 2018-05-21T12:53:55.000Z | 2018-08-27T08:58:38.000Z | test/compute_shifts.jl | andreasnoack/ArnoldiMethod.jl | d44bac4022e5e39f9fa80f6398091c41180ec5a8 | [
"MIT"
] | 12 | 2018-09-10T19:35:02.000Z | 2021-08-03T11:48:46.000Z | using Test
using ArnoldiMethod: eigvalues, local_schurfact!, backward_subst!, compute_shifts, initialize, iterate_arnoldi!
using LinearAlgebra
@testset "Shift computation" begin
for j = 1:20
n = 20
# A = rand(ComplexF64, n,n)
A = triu(rand(ComplexF64, n,n))
for i = 1:n
... | 26.26087 | 111 | 0.55298 | [
"@testset \"Shift computation\" begin\n for j = 1:20\n n = 20\n # A = rand(ComplexF64, n,n)\n A = triu(rand(ComplexF64, n,n))\n for i = 1:n\n A[i,i] = i\n end\n max = 10\n arnoldi = initialize(ComplexF64, n, max)\n iterate_arnoldi!(A, arnoldi, 1:... |
0311d6710f43b9d37a42383de5fe9c60347cd861 | 5,715 | jl | Julia | test/map.jl | nlw0/ImageCore.jl | 6e8a3829b45ed11dec12b67ea94a594c3b40a9e2 | [
"MIT"
] | null | null | null | test/map.jl | nlw0/ImageCore.jl | 6e8a3829b45ed11dec12b67ea94a594c3b40a9e2 | [
"MIT"
] | null | null | null | test/map.jl | nlw0/ImageCore.jl | 6e8a3829b45ed11dec12b67ea94a594c3b40a9e2 | [
"MIT"
] | null | null | null | using ImageCore, FixedPointNumbers, Colors, ColorVectorSpace
using Test
@testset "map" begin
@testset "clamp01" begin
@test clamp01(0.1) === 0.1
@test clamp01(-0.1) === 0.0
@test clamp01(0.9) === 0.9
@test clamp01(1.1) === 1.0
@test clamp01(Inf) === 1.0
@test clamp01... | 36.870968 | 85 | 0.456518 | [
"@testset \"map\" begin\n @testset \"clamp01\" begin\n @test clamp01(0.1) === 0.1\n @test clamp01(-0.1) === 0.0\n @test clamp01(0.9) === 0.9\n @test clamp01(1.1) === 1.0\n @test clamp01(Inf) === 1.0\n @test clamp01(-Inf) === 0.0\n @test isnan(clamp01(NaN))\n ... |
03148dbf42fbb8e52c3bfce9fa97f1063c0cbed9 | 1,006 | jl | Julia | test/test_fermi/test_surface.jl | maryprimary/mary_frg.jl | 981b2bd3e7ac04823a102567ab7c9de1fd482c33 | [
"MIT"
] | null | null | null | test/test_fermi/test_surface.jl | maryprimary/mary_frg.jl | 981b2bd3e7ac04823a102567ab7c9de1fd482c33 | [
"MIT"
] | null | null | null | test/test_fermi/test_surface.jl | maryprimary/mary_frg.jl | 981b2bd3e7ac04823a102567ab7c9de1fd482c33 | [
"MIT"
] | null | null | null | using Test
using MARY_fRG.Triangulated
using MARY_fRG.Fermi
using MARY_fRG.Fermi.Surface
using MARY_fRG.Drawers
@testset "正方格子的费米面" begin
qs = common_square_lattice(0.)
ltris, ladjs = split_square(qs.brillouin, 100)
sf = const_energy_line(ltris, ladjs, 0., qs.dispersion[1])
plt = draw_lines(qs.brilloui... | 33.533333 | 65 | 0.705765 | [
"@testset \"正方格子的费米面\" begin\n qs = common_square_lattice(0.)\n ltris, ladjs = split_square(qs.brillouin, 100)\n sf = const_energy_line(ltris, ladjs, 0., qs.dispersion[1])\n plt = draw_lines(qs.brillouin.edges)\n draw_lines!(plt, sf; lcidx=ones(Int64, length(sf)))\n #draw_polygon!(plt, ltris)\n ... |
03155501310260179c312cbc5dc0d26ae4a4aab3 | 7,551 | jl | Julia | test/code.jl | guanyilun/SymbolicUtils.jl | 029c9fcb70dd202669a9f579dfea595c75b74692 | [
"MIT"
] | null | null | null | test/code.jl | guanyilun/SymbolicUtils.jl | 029c9fcb70dd202669a9f579dfea595c75b74692 | [
"MIT"
] | null | null | null | test/code.jl | guanyilun/SymbolicUtils.jl | 029c9fcb70dd202669a9f579dfea595c75b74692 | [
"MIT"
] | null | null | null | using Test, SymbolicUtils
using SymbolicUtils.Code
using SymbolicUtils.Code: LazyState
using StaticArrays
using LabelledArrays
using SparseArrays
using LinearAlgebra
test_repr(a, b) = @test repr(Base.remove_linenums!(a)) == repr(Base.remove_linenums!(b))
@testset "Code" begin
@syms a b c d e p q t x(t) y(t) z(t)
... | 38.92268 | 115 | 0.380215 | [
"@testset \"Code\" begin\n @syms a b c d e p q t x(t) y(t) z(t)\n @test toexpr(Assignment(a, b)) == :(a = b)\n @test toexpr(a ← b) == :(a = b)\n @test toexpr(a+b) == :($(+)(a, b))\n @test toexpr(a*b*c*d*e) == :($(*)($(*)($(*)($(*)(a, b), c), d), e))\n @test toexpr(a+b+c+d+e) == :($(+)($(+)($(+)($(... |
031a0249565eb901d0c63533a3bbe1fc39c8fdbc | 19,414 | jl | Julia | test/data.jl | ericphanson/DataFrames.jl | 2f5536e92ed9d7002e3a19fa573ffad1d20dc343 | [
"MIT"
] | 1,006 | 2017-09-13T02:13:44.000Z | 2022-03-31T08:06:39.000Z | test/data.jl | ericphanson/DataFrames.jl | 2f5536e92ed9d7002e3a19fa573ffad1d20dc343 | [
"MIT"
] | 1,698 | 2017-09-09T21:53:00.000Z | 2022-03-31T10:48:23.000Z | test/data.jl | ericphanson/DataFrames.jl | 2f5536e92ed9d7002e3a19fa573ffad1d20dc343 | [
"MIT"
] | 251 | 2017-09-12T01:28:17.000Z | 2022-02-27T03:37:54.000Z | module TestData
using Test, DataFrames, Random, Statistics, CategoricalArrays
const ≅ = isequal
@testset "constructors" begin
df1 = DataFrame([[1, 2, missing, 4], ["one", "two", missing, "four"]], [:Ints, :Strs])
df2 = DataFrame([[1, 2, missing, 4], ["one", "two", missing, "four"]], :auto)
df3 = DataFrame... | 40.70021 | 106 | 0.509581 | [
"@testset \"constructors\" begin\n df1 = DataFrame([[1, 2, missing, 4], [\"one\", \"two\", missing, \"four\"]], [:Ints, :Strs])\n df2 = DataFrame([[1, 2, missing, 4], [\"one\", \"two\", missing, \"four\"]], :auto)\n df3 = DataFrame([[1, 2, missing, 4]], :auto)\n df6 = DataFrame([[1, 2, missing, 4], [1, ... |
031af628fc60c3a34912a65adb954446eceffab1 | 16,401 | jl | Julia | test/binaryplatforms.jl | UnofficialJuliaMirror/JuliaLang-Pkg.jl-44cfe95a-1eb2-52ea-b672-e2afdf69b78f | 2d44256d1b935bbfd37ce33ed2552d28ff5fde04 | [
"MIT"
] | null | null | null | test/binaryplatforms.jl | UnofficialJuliaMirror/JuliaLang-Pkg.jl-44cfe95a-1eb2-52ea-b672-e2afdf69b78f | 2d44256d1b935bbfd37ce33ed2552d28ff5fde04 | [
"MIT"
] | null | null | null | test/binaryplatforms.jl | UnofficialJuliaMirror/JuliaLang-Pkg.jl-44cfe95a-1eb2-52ea-b672-e2afdf69b78f | 2d44256d1b935bbfd37ce33ed2552d28ff5fde04 | [
"MIT"
] | null | null | null | module BinaryPlatformTests
import ..Pkg # ensure we are using the correct Pkg
using Test, Pkg.BinaryPlatforms
import Pkg.BinaryPlatforms: gcc_version, platform_name
# The platform we're running on
const platform = platform_key_abi()
@testset "PlatformNames" begin
# Ensure the platform type constructors are well ... | 52.906452 | 211 | 0.663801 | [
"@testset \"PlatformNames\" begin\n # Ensure the platform type constructors are well behaved\n @testset \"Platform constructors\" begin\n @test_throws ArgumentError Linux(:not_a_platform)\n @test_throws ArgumentError Linux(:x86_64; libc=:crazy_libc)\n @test_throws ArgumentError Linux(:x86... |
031b0adef673f6b21f54708e02b548eabcb12ac9 | 3,012 | jl | Julia | test/ExceptionUnwrapping.jl | NHDaly/ExceptionUnwrapping.jl | 60e0c1c0a506f112626cf393df4dcfc4f3e1c986 | [
"MIT"
] | 4 | 2020-03-04T21:25:58.000Z | 2021-10-05T19:06:52.000Z | test/ExceptionUnwrapping.jl | NHDaly/ExceptionUnwrapping.jl | 60e0c1c0a506f112626cf393df4dcfc4f3e1c986 | [
"MIT"
] | 1 | 2020-03-18T16:52:47.000Z | 2020-08-27T01:34:08.000Z | test/ExceptionUnwrapping.jl | NHDaly/ExceptionUnwrapping.jl | 60e0c1c0a506f112626cf393df4dcfc4f3e1c986 | [
"MIT"
] | null | null | null | module ExceptionUnwrappingTest
using Test
using ExceptionUnwrapping
using ExceptionUnwrapping: UnwrappedExceptionNotFound
# TaskFailedException is available in Julia 1.3+
if VERSION >= v"1.3.0-"
@testset "Wrapped TaskFailedException" begin
try
fetch(@async fetch(@async error("hi")))
c... | 34.227273 | 126 | 0.697875 | [
"@testset \"Custom Exception Types\" begin\n e1 = ErrorException(\"1\")\n e2 = MyWrappedException(ErrorException(\"1\"))\n try\n throw(e2)\n catch e\n @assert e === e2\n @assert (e isa ErrorException) == false\n @assert e isa MyWrappedException\n\n @test is_wrapped_exc... |
031b6bc7f2a9ea5458e78494558fd8a9ebf54f49 | 2,080 | jl | Julia | test/UnitTests/projections.jl | msarfati/COSMO.jl | c12d46c485ddccba286d3447d60d1cb399402119 | [
"Apache-2.0"
] | 210 | 2018-12-11T23:45:52.000Z | 2022-03-17T23:11:26.000Z | test/UnitTests/projections.jl | msarfati/COSMO.jl | c12d46c485ddccba286d3447d60d1cb399402119 | [
"Apache-2.0"
] | 110 | 2018-12-12T15:52:17.000Z | 2022-03-20T00:44:39.000Z | test/UnitTests/projections.jl | msarfati/COSMO.jl | c12d46c485ddccba286d3447d60d1cb399402119 | [
"Apache-2.0"
] | 39 | 2019-03-10T06:40:11.000Z | 2022-03-23T08:53:29.000Z | # Test file to check the projections
# workspace()
# include("../src/Solver.jl")
using Test, COSMOTestUtils, COSMO.Projections, LinearAlgebra, SparseArrays
rng = Random.MersenneTwister(1234)
nn = 1
@testset "Test projection onto zero cone" begin
x = rand(rng, rand(rng, 1:100))
Projections.zeroCone!(... | 24.186047 | 79 | 0.56875 | [
"@testset \"Test projection onto zero cone\" begin\n x = rand(rng, rand(rng, 1:100))\n Projections.zeroCone!(x, 1, length(x))\n @test x == zeros(size(x, 1))\nend",
"@testset \"Test projection onto nonNegativeOrthant\" begin\n for iii = 1:nn\n dim = rand(rng, 1:100)\n x = rand... |
031c3c81def2c3c05f7f223426fac590a7a5ea2e | 6,344 | jl | Julia | test/runtests.jl | Argonne-National-Laboratory/MaximinOPF.jl | c24f001336d11d98ffcaa5a08a04ba53ed7f7dce | [
"MIT"
] | 5 | 2020-04-07T21:12:11.000Z | 2022-03-14T06:31:07.000Z | test/runtests.jl | Argonne-National-Laboratory/MaximinOPF.jl | c24f001336d11d98ffcaa5a08a04ba53ed7f7dce | [
"MIT"
] | 22 | 2020-04-16T02:51:50.000Z | 2020-06-11T22:03:37.000Z | test/runtests.jl | Argonne-National-Laboratory/MaximinOPF.jl | c24f001336d11d98ffcaa5a08a04ba53ed7f7dce | [
"MIT"
] | 1 | 2020-06-25T16:47:55.000Z | 2020-06-25T16:47:55.000Z | using MaximinOPF
using PowerModels
using JuMP
using SCS, Ipopt
using Test
include("testcases.jl")
PowerModels.silence()
function run_instance(testcase, PMOption, maximin = true, is_conic = true)
pm_data = PowerModels.parse_file( testcase["file"] )
pm_form = PMOption
pm_data["name"]=testcase["name"]
pm... | 35.049724 | 123 | 0.6064 | [
"@testset \"Maximin Model Tests\" begin\n println(\"Maximin Models:\")\n @testset \"SOC Model Tests\" begin\n println(\"Type: SOCWRConicPowerModel\")\n for case in testcases\n run_instance(case, SOCWRConicPowerModel)\n end\n end\n @testset \"SDP Model Tests\" begin\n ... |
031cdad9868c19eb7b964b0b3261a9661d5e6081 | 89 | jl | Julia | test/runtests.jl | komatsu5147/HaloMF.jl | 70a2329082fa4b797f7b1e3ab9891d74c72218c9 | [
"MIT"
] | null | null | null | test/runtests.jl | komatsu5147/HaloMF.jl | 70a2329082fa4b797f7b1e3ab9891d74c72218c9 | [
"MIT"
] | null | null | null | test/runtests.jl | komatsu5147/HaloMF.jl | 70a2329082fa4b797f7b1e3ab9891d74c72218c9 | [
"MIT"
] | null | null | null | using HaloMF
using Test
@testset "HaloMF.jl" begin
# Write your own tests here.
end
| 12.714286 | 32 | 0.719101 | [
"@testset \"HaloMF.jl\" begin\n # Write your own tests here.\nend"
] |
031e1716fb45e08bb42a6e49c7088a1db2ebf994 | 4,839 | jl | Julia | test/runtests.jl | giordano/LicenseCheck.jl | d1bc60332cae406cbff86dfeb7023195dcadb2c3 | [
"MIT"
] | null | null | null | test/runtests.jl | giordano/LicenseCheck.jl | d1bc60332cae406cbff86dfeb7023195dcadb2c3 | [
"MIT"
] | null | null | null | test/runtests.jl | giordano/LicenseCheck.jl | d1bc60332cae406cbff86dfeb7023195dcadb2c3 | [
"MIT"
] | null | null | null | using LicenseCheck
using Test
MIT = """
MIT License Copyright (c) <year> <copyright holders>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without... | 43.594595 | 148 | 0.694978 | [
"@testset \"LicenseCheck\" begin\n @testset \"`licensecheck`\" begin\n result = licensecheck(MIT)\n @test result.licenses_found == [\"MIT\"]\n @test result.license_file_percent_covered ≈ 100.0 atol = 2\n\n result = licensecheck(MIT * \"\\n\" * Latex2e)\n @test result.licenses_f... |
0322d04d4168296bf1e6753b34279295b6ca9edb | 1,681 | jl | Julia | test/chunking.jl | quatrix/HTTP.jl | 657dbf9a5d1d87e6e085158a5a053553fcaed032 | [
"MIT"
] | null | null | null | test/chunking.jl | quatrix/HTTP.jl | 657dbf9a5d1d87e6e085158a5a053553fcaed032 | [
"MIT"
] | null | null | null | test/chunking.jl | quatrix/HTTP.jl | 657dbf9a5d1d87e6e085158a5a053553fcaed032 | [
"MIT"
] | null | null | null | using Test
using HTTP
using BufferedStreams
# For more information see: https://github.com/JuliaWeb/HTTP.jl/pull/288
@testset "Chunking" begin
sz = 90
hex(n) = string(n, base=16)
encoded_data = "$(hex(sz + 9))\r\n" * "data: 1$(repeat("x", sz))\n\n" * "\r\n" *
"$(hex(sz + 9))\r\n" * "data... | 27.557377 | 84 | 0.516954 | [
"@testset \"Chunking\" begin\n sz = 90\n hex(n) = string(n, base=16)\n encoded_data = \"$(hex(sz + 9))\\r\\n\" * \"data: 1$(repeat(\"x\", sz))\\n\\n\" * \"\\r\\n\" *\n \"$(hex(sz + 9))\\r\\n\" * \"data: 2$(repeat(\"x\", sz))\\n\\n\" * \"\\r\\n\" *\n \"$(hex(sz + 9))\\r\\... |
0323145d8c2f1c3dd4ab5d5447a93967e7807c0f | 43,813 | jl | Julia | test/runtests.jl | simonbyrne/BinaryProvider.jl | cb403e6e19c5ec130b47cf3d85d8e9530adabd14 | [
"MIT"
] | null | null | null | test/runtests.jl | simonbyrne/BinaryProvider.jl | cb403e6e19c5ec130b47cf3d85d8e9530adabd14 | [
"MIT"
] | null | null | null | test/runtests.jl | simonbyrne/BinaryProvider.jl | cb403e6e19c5ec130b47cf3d85d8e9530adabd14 | [
"MIT"
] | null | null | null | using BinaryProvider
using Test
using Libdl
using Pkg
using SHA
# The platform we're running on
const platform = platform_key_abi()
# Useful command to launch `sh` on any platform
const sh = gen_sh_cmd
# Output of a few scripts we are going to run
const simple_out = "1\n2\n3\n4\n"
const long_out = join(["$(idx)\n" f... | 43.988956 | 178 | 0.648232 | [
"@testset \"OutputCollector\" begin\n cd(\"output_tests\") do\n # Collect the output of `simple.sh``\n oc = OutputCollector(sh(`./simple.sh`))\n\n # Ensure we can wait on it and it exited properly\n @test wait(oc)\n\n # Ensure further waits are fast and still return 0\n ... |
0325a98f2bc7abadcaf581ba1f41c138ed277fa7 | 3,719 | jl | Julia | test/ControlUnit_tests.jl | ktchu/Boid.jl | 8b4b01ef70a4e9cbbb921fbe1d807e71d3ed0c94 | [
"Apache-2.0"
] | null | null | null | test/ControlUnit_tests.jl | ktchu/Boid.jl | 8b4b01ef70a4e9cbbb921fbe1d807e71d3ed0c94 | [
"Apache-2.0"
] | 4 | 2022-03-22T06:10:14.000Z | 2022-03-25T00:36:07.000Z | test/ControlUnit_tests.jl | ktchu/Boid.jl | 8b4b01ef70a4e9cbbb921fbe1d807e71d3ed0c94 | [
"Apache-2.0"
] | null | null | null | """
Unit tests for ControlUnit type.
------------------------------------------------------------------------------
COPYRIGHT/LICENSE. This file is part of the XYZ package. It is subject to
the license terms in the LICENSE file found in the top-level directory of
this distribution. No part of the XYZ package, includin... | 25.648276 | 78 | 0.685668 | [
"@testset \"ControlUnit: constructor\" begin\n # --- Preparations\n\n logic_core = TestControlLogicCore()\n\n # --- Tests\n\n # copy_logic_core == true\n control_unit = ControlUnit(logic_core, control_url)\n\n @test control_unit.logic_core isa TestControlLogicCore\n @test control_unit.logic_cor... |
03263cf7dab3f6c428393e60c9e49c5a6e6aa8f9 | 1,409 | jl | Julia | test/runtests.jl | NREL-SIIP/PowerSystemBuilder.jl | 5ecff075ce9bc83eb5a27cfe8269cfc036f210e1 | [
"BSD-3-Clause"
] | 5 | 2021-01-28T16:48:45.000Z | 2021-12-16T13:15:18.000Z | test/runtests.jl | NREL-SIIP/PowerSystemCaseBuilder.jl | 5ecff075ce9bc83eb5a27cfe8269cfc036f210e1 | [
"BSD-3-Clause"
] | 30 | 2021-01-16T00:59:46.000Z | 2022-03-09T01:43:09.000Z | test/runtests.jl | NREL-SIIP/PowerSystemBuilder.jl | 5ecff075ce9bc83eb5a27cfe8269cfc036f210e1 | [
"BSD-3-Clause"
] | 3 | 2021-01-28T16:49:07.000Z | 2021-06-17T21:02:42.000Z | using Test
using Logging
using DataStructures
using Dates
using TimeSeries
using InfrastructureSystems
const IS = InfrastructureSystems
using PowerSystems
const PSY = PowerSystems
using PowerSystemCaseBuilder
const PSB = PowerSystemCaseBuilder
@testset "Test Serializtion/De-Serializtion" begin
system_catelog = Sys... | 32.022727 | 69 | 0.561391 | [
"@testset \"Test Serializtion/De-Serializtion\" begin\n system_catelog = SystemCatalog(SYSTEM_CATALOG)\n for (type, descriptor_dict) in system_catelog.data\n for (name, descriptor) in descriptor_dict\n name == \"c_sys5_hybrid\" && continue\n for forecasts in [true, false], reserve... |
032666c1439ced39bf755ba7eead8e8f4aceb183 | 263 | jl | Julia | test/runtests.jl | EdwardStables/CI_Test | 5dac80beacd5d882e12322629e65b8c4b2478aec | [
"MIT"
] | null | null | null | test/runtests.jl | EdwardStables/CI_Test | 5dac80beacd5d882e12322629e65b8c4b2478aec | [
"MIT"
] | null | null | null | test/runtests.jl | EdwardStables/CI_Test | 5dac80beacd5d882e12322629e65b8c4b2478aec | [
"MIT"
] | null | null | null | using CI_Test
using Test
@testset "CI_Test.jl" begin
# Write your own tests here.
alphabet = "abcdefghijklmnopqrstuvwxyz"
d = CI_Test.TerribleGreek()
@test typeof(d) == Dict{Char,Char}
for c in keys(d)
@test c in alphabet
end
end
| 20.230769 | 43 | 0.657795 | [
"@testset \"CI_Test.jl\" begin\n # Write your own tests here.\n alphabet = \"abcdefghijklmnopqrstuvwxyz\"\n d = CI_Test.TerribleGreek()\n @test typeof(d) == Dict{Char,Char}\n for c in keys(d)\n @test c in alphabet\n end\nend"
] |
0326ba521011db1f13e6c01b6e8b77bb97878451 | 194 | jl | Julia | test/runtests.jl | JuliaFolds/GeneratorsX.jl | 7c0ba25a21fbf5bde6be61f4e5a88c6e9ea37054 | [
"MIT"
] | 14 | 2020-06-14T04:36:13.000Z | 2022-02-07T01:49:36.000Z | test/runtests.jl | tkf/GeneratorsX.jl | 7c0ba25a21fbf5bde6be61f4e5a88c6e9ea37054 | [
"MIT"
] | 22 | 2020-06-14T07:48:16.000Z | 2020-09-10T21:44:39.000Z | test/runtests.jl | tkf/GeneratorsX.jl | 7c0ba25a21fbf5bde6be61f4e5a88c6e9ea37054 | [
"MIT"
] | null | null | null | module TestGeneratorsX
using Test
@testset "$file" for file in sort([
file for file in readdir(@__DIR__) if match(r"^test_.*\.jl$", file) !== nothing
])
include(file)
end
end # module
| 19.4 | 83 | 0.670103 | [
"@testset \"$file\" for file in sort([\n file for file in readdir(@__DIR__) if match(r\"^test_.*\\.jl$\", file) !== nothing\n])\n include(file)\nend"
] |
0326f301d1d7c116faa133b5e4e9f387df77fc1a | 2,658 | jl | Julia | src/Abundant.jl | OpenLibMathSeq/Sequences | e53c1f30b7bf81669805f21d408d407b727615b5 | [
"MIT"
] | 6 | 2019-06-25T08:54:44.000Z | 2021-11-07T04:52:29.000Z | src/Abundant.jl | OpenLibMathSeq/Sequences | e53c1f30b7bf81669805f21d408d407b727615b5 | [
"MIT"
] | 3 | 2019-04-30T19:07:41.000Z | 2019-06-04T15:51:34.000Z | src/Abundant.jl | PeterLuschny/IntegerSequences.jl | 1b9440bc8b86e3ae74fd26ee48fba412befbbdb5 | [
"MIT"
] | 4 | 2019-04-30T17:00:10.000Z | 2020-02-08T11:32:39.000Z | # This file is part of IntegerSequences.
# Copyright Peter Luschny. License is MIT.
(@__DIR__) ∉ LOAD_PATH && push!(LOAD_PATH, (@__DIR__))
module Abundant
using NumberTheory, IterTools, Counts
export ModuleAbundant
export isAbundant, is005101, I005101, F005101, L005101, V005101
"""
``n`` is an abundant number if `... | 17.602649 | 152 | 0.577502 | [
"@testset \"Abundant\" begin\n @test isAbundant(100800) == true\n @test isAbundant(2402400) == true\n @test isAbundant(49008960) == true\n\n if data_installed()\n SeqTest([L005101], 'L')\n end\n end"
] |
0329580f47c65e14932b1217bae3673eb44bc9f9 | 2,914 | jl | Julia | test/test_tree_2d_mhdmulti.jl | FelipeSantillan/Trixi.jl | 9ee86ebb95dbcbf90fca6e4bea011567d06c44f9 | [
"MIT"
] | 1 | 2020-10-06T08:28:35.000Z | 2020-10-06T08:28:35.000Z | test/test_tree_2d_mhdmulti.jl | FelipeSantillan/Trixi.jl | 9ee86ebb95dbcbf90fca6e4bea011567d06c44f9 | [
"MIT"
] | null | null | null | test/test_tree_2d_mhdmulti.jl | FelipeSantillan/Trixi.jl | 9ee86ebb95dbcbf90fca6e4bea011567d06c44f9 | [
"MIT"
] | null | null | null | module TestExamples2DEulerMulticomponent
using Test
using Trixi
include("test_trixi.jl")
# pathof(Trixi) returns /path/to/Trixi/src/Trixi.jl, dirname gives the parent directory
EXAMPLES_DIR = joinpath(pathof(Trixi) |> dirname |> dirname, "examples", "tree_2d_dgsem")
@testset "MHD Multicomponent" begin
@trixi_tes... | 51.122807 | 104 | 0.736102 | [
"@testset \"MHD Multicomponent\" begin\n\n @trixi_testset \"elixir_mhdmulti_ec.jl\" begin\n @test_trixi_include(joinpath(EXAMPLES_DIR, \"elixir_mhdmulti_ec.jl\"),\n l2 = [0.04300299195675897, 0.042987505670835945, 0.025747180552589767, 0.1621856170457937,\n 0.017453693413025828, 0.0174545523... |
032ac76bb9184815709d7298a5393b12662d2340 | 144 | jl | Julia | test/runtests.jl | Mikejmnez/MyExample | 6dbce14d77307e6d57051686a0d70cd793c6b671 | [
"MIT"
] | null | null | null | test/runtests.jl | Mikejmnez/MyExample | 6dbce14d77307e6d57051686a0d70cd793c6b671 | [
"MIT"
] | null | null | null | test/runtests.jl | Mikejmnez/MyExample | 6dbce14d77307e6d57051686a0d70cd793c6b671 | [
"MIT"
] | null | null | null | using MyExample
using Test
@testset "MyExample.jl" begin
@test my_f(2, 1) == 7
@test my_f(2, 3) == 13
@test new_f(1, 2) == 0.5
end
| 16 | 29 | 0.590278 | [
"@testset \"MyExample.jl\" begin\n @test my_f(2, 1) == 7\n @test my_f(2, 3) == 13\n @test new_f(1, 2) == 0.5\nend"
] |
032cb6d05c2fb7acd01a9d16001927b08d83a374 | 2,279 | jl | Julia | test/runtests.jl | Alexander-Barth/CairoMakie.jl | 65d81fbf597325128ce1ffde09fa85c3f3184912 | [
"MIT"
] | 33 | 2019-01-09T10:18:36.000Z | 2021-12-12T23:53:56.000Z | test/runtests.jl | Alexander-Barth/CairoMakie.jl | 65d81fbf597325128ce1ffde09fa85c3f3184912 | [
"MIT"
] | 106 | 2018-12-12T19:13:35.000Z | 2021-06-24T09:02:13.000Z | test/runtests.jl | Alexander-Barth/CairoMakie.jl | 65d81fbf597325128ce1ffde09fa85c3f3184912 | [
"MIT"
] | 17 | 2018-12-07T10:18:07.000Z | 2021-06-10T20:30:25.000Z | using Test, Pkg
using CairoMakie
# Before changing Pkg environment, try the test in #864
@testset "Runs without error" begin
fig = Figure()
scatter(fig[1, 1], rand(10))
fn = tempname()*".png"
try
save(fn, fig)
finally
rm(fn)
end
end
path = normpath(joinpath(dirname(pathof(Makie... | 27.130952 | 81 | 0.655551 | [
"@testset \"Runs without error\" begin\n fig = Figure()\n scatter(fig[1, 1], rand(10))\n fn = tempname()*\".png\"\n try\n save(fn, fig)\n finally\n rm(fn)\n end\nend"
] |
033028de60216e2b5bb1324e6e3444e4dc454685 | 446 | jl | Julia | test/test_wip/test_target_ts.jl | klorel/pscopf | 3dd4af44143272a78ca5ba81b04ff0909a1f0947 | [
"Apache-2.0"
] | null | null | null | test/test_wip/test_target_ts.jl | klorel/pscopf | 3dd4af44143272a78ca5ba81b04ff0909a1f0947 | [
"Apache-2.0"
] | 28 | 2022-03-08T17:01:33.000Z | 2022-03-28T13:09:41.000Z | test/test_wip/test_target_ts.jl | klorel/pscopf | 3dd4af44143272a78ca5ba81b04ff0909a1f0947 | [
"Apache-2.0"
] | 1 | 2021-12-20T14:28:07.000Z | 2021-12-20T14:28:07.000Z | using PSCOPF
using Test
using Dates
@testset "test_target_ts" begin
ts1 = DateTime("2015-01-01T11:00:00")
TS = PSCOPF.create_target_timepoints(ts1)
EXPECTED_TS = [DateTime("2015-01-01T11:00:00"),
DateTime("2015-01-01T11:15:00"),
DateTime("2015-01-01T11:30:00"),
... | 26.235294 | 52 | 0.603139 | [
"@testset \"test_target_ts\" begin\n ts1 = DateTime(\"2015-01-01T11:00:00\")\n TS = PSCOPF.create_target_timepoints(ts1)\n\n EXPECTED_TS = [DateTime(\"2015-01-01T11:00:00\"),\n DateTime(\"2015-01-01T11:15:00\"),\n DateTime(\"2015-01-01T11:30:00\"),\n ... |
0333685579bc94b97e7e58716721c298e97a11ac | 6,193 | jl | Julia | stdlib/LinearAlgebra/test/bunchkaufman.jl | greimel/julia | 1c6f89f04a1ee4eba8380419a2b01426e84f52aa | [
"Zlib"
] | 18 | 2018-03-17T16:54:52.000Z | 2021-11-14T20:28:51.000Z | stdlib/LinearAlgebra/test/bunchkaufman.jl | greimel/julia | 1c6f89f04a1ee4eba8380419a2b01426e84f52aa | [
"Zlib"
] | 8 | 2018-09-27T01:16:58.000Z | 2018-12-05T23:33:08.000Z | stdlib/LinearAlgebra/test/bunchkaufman.jl | greimel/julia | 1c6f89f04a1ee4eba8380419a2b01426e84f52aa | [
"Zlib"
] | 3 | 2018-03-21T14:40:39.000Z | 2020-05-04T19:15:03.000Z | # This file is a part of Julia. License is MIT: https://julialang.org/license
module TestBunchKaufman
using Test, LinearAlgebra, Random
using LinearAlgebra: BlasComplex, BlasFloat, BlasReal, QRPivoted
using Base: getproperty
n = 10
# Split n into 2 parts for tests needing two matrices
n1 = div(n, 2)
n2 = 2*n1
Rand... | 44.876812 | 121 | 0.535928 | [
"@testset \"$eltya argument A\" for eltya in (Float32, Float64, ComplexF32, ComplexF64, Int)\n a = eltya == Int ? rand(1:7, n, n) : convert(Matrix{eltya}, eltya <: Complex ? complex.(areal, aimg) : areal)\n a2 = eltya == Int ? rand(1:7, n, n) : convert(Matrix{eltya}, eltya <: Complex ? complex.(a2real, a2img)... |
0339130e62e0fde05a4dc5e491fc796f268b2153 | 174 | jl | Julia | test/runtests.jl | Roger-luo/GarishPrint.jl | e8926540288fccd29a6f986ef41bd345e8b51080 | [
"MIT"
] | 16 | 2021-06-21T15:56:03.000Z | 2022-03-27T14:21:12.000Z | test/runtests.jl | Roger-luo/GarishPrint.jl | e8926540288fccd29a6f986ef41bd345e8b51080 | [
"MIT"
] | 10 | 2021-06-24T22:43:38.000Z | 2022-02-19T07:32:42.000Z | test/runtests.jl | Roger-luo/GarishPrint.jl | e8926540288fccd29a6f986ef41bd345e8b51080 | [
"MIT"
] | 1 | 2021-12-01T09:20:14.000Z | 2021-12-01T09:20:14.000Z | using Test
@static if VERSION ≥ v"1.6"
@testset "prefs" begin
include("prefs.jl")
end
end
include("basic.jl")
include("configs.jl")
include("dataframe.jl")
| 14.5 | 27 | 0.643678 | [
"@static if VERSION ≥ v\"1.6\"\n @testset \"prefs\" begin\n include(\"prefs.jl\")\n end\nend"
] |
033db97b9ff12a01b18b3a24afdada5bbb238084 | 974 | jl | Julia | test/runtests.jl | JuliaNeuroscience/NeuroGraphs.jl | e67f4a5584e403cf3c88e01181017f7ac08a6b92 | [
"MIT"
] | 1 | 2022-01-07T21:43:43.000Z | 2022-01-07T21:43:43.000Z | test/runtests.jl | JuliaNeuroscience/NeuroGraphs.jl | e67f4a5584e403cf3c88e01181017f7ac08a6b92 | [
"MIT"
] | null | null | null | test/runtests.jl | JuliaNeuroscience/NeuroGraphs.jl | e67f4a5584e403cf3c88e01181017f7ac08a6b92 | [
"MIT"
] | null | null | null | using Test
using NeuroGraphs
using LightGraphs
g = WAdjMap(3) # or use `SimpleWeightedDiGraph` for directed graphs
add_edge!(g, 1, 2, 0.5)
add_edge!(g, 2, 3, 0.8)
add_edge!(g, 1, 3, 2.0)
LightGraphs.DijkstraState{Int64, Int64}([0, 0, 0], [0, 9223372036854775807, 9223372036854775807], [Int64[], Int
64[], Int64[]], [1... | 23.190476 | 111 | 0.63963 | [
"@testset \"NeuroGraphs.jl\" begin\n g = AdjMap(3)\n\n\n g5 = AdjDiMap(4)\n add_edge!(g5, 1, 2);\n add_edge!(g5, 2, 3);\n add_edge!(g5, 1, 3);\n add_edge!(g5, 3, 4)\n # Write your tests here.\nend"
] |
033e807549e7715d2c0890a41946053162647946 | 460 | jl | Julia | test/runtests.jl | JuliaFolds/SplittablesTesting.jl | 24a8f7527c23ebf5ca95c3283d669e5376a53a0f | [
"MIT"
] | null | null | null | test/runtests.jl | JuliaFolds/SplittablesTesting.jl | 24a8f7527c23ebf5ca95c3283d669e5376a53a0f | [
"MIT"
] | 1 | 2020-06-07T07:19:46.000Z | 2020-07-28T01:28:48.000Z | test/runtests.jl | JuliaFolds/SplittablesTesting.jl | 24a8f7527c23ebf5ca95c3283d669e5376a53a0f | [
"MIT"
] | null | null | null | using SplittablesTesting
using Test
@testset "test_ordered" begin
SplittablesTesting.test_ordered([
(label = "First Test", data = 1:5),
(label = "Second Test", data = (a = 1, b = 2, c = 3)),
zip(1:3, 4:6),
])
end
@testset "test_unordered" begin
SplittablesTesting.test_unordered([
... | 24.210526 | 62 | 0.552174 | [
"@testset \"test_ordered\" begin\n SplittablesTesting.test_ordered([\n (label = \"First Test\", data = 1:5),\n (label = \"Second Test\", data = (a = 1, b = 2, c = 3)),\n zip(1:3, 4:6),\n ])\nend",
"@testset \"test_unordered\" begin\n SplittablesTesting.test_unordered([\n (labe... |
034180d1f474252173ff156583150c284a07f7d1 | 254 | jl | Julia | test/runtests.jl | BoZenKhaa/Mdp.jl | 27ad50d6c76b251f4157d2919a1de88a5f8e5347 | [
"MIT"
] | null | null | null | test/runtests.jl | BoZenKhaa/Mdp.jl | 27ad50d6c76b251f4157d2919a1de88a5f8e5347 | [
"MIT"
] | null | null | null | test/runtests.jl | BoZenKhaa/Mdp.jl | 27ad50d6c76b251f4157d2919a1de88a5f8e5347 | [
"MIT"
] | null | null | null | using Mdp
using Test
@testset "VI.jl" begin
include("test_vi.jl")
end
@testset "FH.jl" begin
include("test_fh.jl")
end
include("test_pricing_problem.jl")
@testset "PricingAlgorithmFH.jl" begin
include("test_pricing_algorithm_fh.jl")
end
| 14.111111 | 43 | 0.728346 | [
"@testset \"VI.jl\" begin\n include(\"test_vi.jl\")\nend",
"@testset \"FH.jl\" begin\n include(\"test_fh.jl\")\nend",
"@testset \"PricingAlgorithmFH.jl\" begin\n include(\"test_pricing_algorithm_fh.jl\")\nend"
] |
034499add374b651f777660e790cf1fd2e6cf439 | 5,083 | jl | Julia | test/tesseract/tess_pipeline_lstm_box.jl | pixel27/Tesseract.jl | fe93f30c0e8d1106764e42dec8bd9898ea8e699e | [
"MIT"
] | 6 | 2020-08-06T20:53:25.000Z | 2022-03-27T21:19:54.000Z | test/tesseract/tess_pipeline_lstm_box.jl | pixel27/Tesseract.jl | fe93f30c0e8d1106764e42dec8bd9898ea8e699e | [
"MIT"
] | 5 | 2020-05-05T01:51:18.000Z | 2021-12-28T13:59:54.000Z | test/tesseract/tess_pipeline_lstm_box.jl | pixel27/Tesseract.jl | fe93f30c0e8d1106764e42dec8bd9898ea8e699e | [
"MIT"
] | 1 | 2021-09-08T16:36:04.000Z | 2021-09-08T16:36:04.000Z | # MIT License
#
# Copyright (c) 2020 Joshua E Gentry
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merg... | 41.663934 | 91 | 0.608302 | [
"@testset \"tess_pipeline_lstm_box() => Filename\" begin\n local inst = TessInst(\"eng\", datadir)\n local pipeline = TessPipeline(inst)\n local output, io = mktemp(;cleanup=false); close(io)\n\n @test tess_pipeline_lstm_box(pipeline, output) == true\n\n @test (tess_run_pipeline(pipeline) do ... |
0345cdbcc9705a6a5c9997902ad2a296ce4fac79 | 232 | jl | Julia | test/runtests.jl | kleinschmidt/RegressionFormulae.jl | 342b034a97648585e4394f4d9a3b12aa1798a6df | [
"MIT"
] | 5 | 2020-04-30T21:30:49.000Z | 2022-01-27T03:33:42.000Z | test/runtests.jl | kleinschmidt/RegressionFormulae.jl | 342b034a97648585e4394f4d9a3b12aa1798a6df | [
"MIT"
] | 2 | 2020-04-28T18:41:50.000Z | 2022-01-26T18:48:05.000Z | test/runtests.jl | kleinschmidt/RegressionFormulae.jl | 342b034a97648585e4394f4d9a3b12aa1798a6df | [
"MIT"
] | null | null | null | using RegressionFormulae
using StatsModels
using Test
@testset "fulldummy" begin
include("fulldummy.jl")
end
@testset "nesting" begin
include("nesting.jl")
end
@testset "powers of terms" begin
include("power.jl")
end
| 14.5 | 32 | 0.732759 | [
"@testset \"fulldummy\" begin\n include(\"fulldummy.jl\")\nend",
"@testset \"nesting\" begin\n include(\"nesting.jl\")\nend",
"@testset \"powers of terms\" begin\n include(\"power.jl\")\nend"
] |
03487cc353089f7f821b86ec0a66d5b661ebe1c6 | 101,932 | jl | Julia | bin/julia/share/julia/test/numbers.jl | justletterh/why | 868f56a2e71cb99c755d621b05938fe444816fe9 | [
"Unlicense"
] | null | null | null | bin/julia/share/julia/test/numbers.jl | justletterh/why | 868f56a2e71cb99c755d621b05938fe444816fe9 | [
"Unlicense"
] | null | null | null | bin/julia/share/julia/test/numbers.jl | justletterh/why | 868f56a2e71cb99c755d621b05938fe444816fe9 | [
"Unlicense"
] | null | null | null | # This file is a part of Julia. License is MIT: https://julialang.org/license
using Base.MathConstants
using Random
using LinearAlgebra
const ≣ = isequal # convenient for comparing NaNs
@testset "basic booleans" begin
@test true
@test !false
@test !!true
@test !!!false
@test true == true
@t... | 37.907029 | 178 | 0.570665 | [
"@testset \"basic booleans\" begin\n @test true\n @test !false\n @test !!true\n @test !!!false\n\n @test true == true\n @test false == false\n @test true != false\n @test false != true\n\n @test ~true == false\n @test ~false == true\n\n @test false & false == false\n @test true... |
0349267eeb8f9f05841dd0a10e5f5c2645a0339f | 3,247 | jl | Julia | Test/test_evaporation.jl | sarah-hanus/hbv-mountain | bba8b06b311dec3fcdca77179eef2751dd548255 | [
"MIT"
] | 2 | 2021-04-08T12:26:24.000Z | 2021-06-17T20:52:55.000Z | Test/test_evaporation.jl | sarah-hanus/hbv-mountain | bba8b06b311dec3fcdca77179eef2751dd548255 | [
"MIT"
] | null | null | null | Test/test_evaporation.jl | sarah-hanus/hbv-mountain | bba8b06b311dec3fcdca77179eef2751dd548255 | [
"MIT"
] | null | null | null | using Test
using Dates
using Statistics
# @testset "evaporation" begin
# for i in 1:5000
# Ra = rand(10:0.1:40)
# Tmin= rand(0.1:0.1:20)
# Tmax = rand(Tmin:0.1:25)
# Kt = 0.17
# Evap = 0.0135 * Kt * ((Tmin + Tmax)/2 + 17.8) * (Tmax - Tmin)^0.5 * Ra
#
# @test round(ep... | 39.597561 | 116 | 0.595319 | [
"@testset \"evaporation_thorn\" begin\n for i in 1:100000\n year = rand(1980:2020)[1]\n month = rand(1:12)[1]\n Begin_Month = Dates.firstdayofmonth(Date(year,month,1))\n End_Month = Dates.lastdayofmonth(Date(year,month,1))\n Timeseries = Begin_Month:Day(1):End_Month\n Te... |
034c22780cac32c8304d1d5dde0dcb61fe0dd4f6 | 4,871 | jl | Julia | test/multipath.jl | sethaxen/Pathfinder.jl | 2723aff76de10bf196ff1afc8a9f41e879707b17 | [
"MIT"
] | 11 | 2021-10-16T12:11:03.000Z | 2022-02-17T12:26:06.000Z | test/multipath.jl | sethaxen/Pathfinder.jl | 2723aff76de10bf196ff1afc8a9f41e879707b17 | [
"MIT"
] | 25 | 2021-10-17T00:51:14.000Z | 2022-02-08T09:38:22.000Z | test/multipath.jl | sethaxen/Pathfinder.jl | 2723aff76de10bf196ff1afc8a9f41e879707b17 | [
"MIT"
] | 2 | 2021-10-17T21:46:58.000Z | 2021-12-16T21:51:33.000Z | using AbstractDifferentiation
using Distributions
using ForwardDiff
using LinearAlgebra
using GalacticOptim
using Pathfinder
using PSIS
using ReverseDiff
using SciMLBase
using Test
using Transducers
@testset "multi path pathfinder" begin
@testset "MvNormal" begin
dim = 10
nruns = 20
ndraws ... | 39.601626 | 92 | 0.586738 | [
"@testset \"multi path pathfinder\" begin\n @testset \"MvNormal\" begin\n dim = 10\n nruns = 20\n ndraws = 1000_000\n ndraws_per_run = ndraws ÷ nruns\n ndraws_elbo = 100\n Σ = rand_pd_mat(Float64, dim)\n μ = randn(dim)\n d = MvNormal(μ, Σ)\n logp(x) ... |
03503ff8024f8658082f740c4702ce1c561fa665 | 4,347 | jl | Julia | experiments/OceanBoxGCM/ocean_gyre.jl | felixcremer/ClimateMachine.jl | e704c2c1172d8ae9e253080ba7c84b5f2fe5ed7b | [
"Apache-2.0"
] | null | null | null | experiments/OceanBoxGCM/ocean_gyre.jl | felixcremer/ClimateMachine.jl | e704c2c1172d8ae9e253080ba7c84b5f2fe5ed7b | [
"Apache-2.0"
] | null | null | null | experiments/OceanBoxGCM/ocean_gyre.jl | felixcremer/ClimateMachine.jl | e704c2c1172d8ae9e253080ba7c84b5f2fe5ed7b | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env julia --project
using CLIMA
CLIMA.init()
using CLIMA.GenericCallbacks
using CLIMA.ODESolvers
using CLIMA.Mesh.Filters
using CLIMA.VariableTemplates
using CLIMA.Mesh.Grids: polynomialorder
using CLIMA.HydrostaticBoussinesq
using Test
using CLIMAParameters
using CLIMAParameters.Planet: grav
struct EarthP... | 30.1875 | 80 | 0.656085 | [
"@testset \"$(@__FILE__)\" begin\n boundary_conditions = [\n (\n CLIMA.HydrostaticBoussinesq.CoastlineNoSlip(),\n CLIMA.HydrostaticBoussinesq.OceanFloorNoSlip(),\n CLIMA.HydrostaticBoussinesq.OceanSurfaceStressForcing(),\n ),\n (\n CLIMA.Hydrostati... |
0351266d7d4662f550a8f42fe9953de7a6159ad5 | 1,500 | jl | Julia | test/MultiTest.jl | JuliaTagBot/TaskHeritableStorage.jl | 3ecb11693d45c48007de2c15aefc461f53ea9138 | [
"MIT"
] | null | null | null | test/MultiTest.jl | JuliaTagBot/TaskHeritableStorage.jl | 3ecb11693d45c48007de2c15aefc461f53ea9138 | [
"MIT"
] | 2 | 2019-11-04T20:03:36.000Z | 2019-11-05T00:45:03.000Z | test/MultiTest.jl | JuliaTagBot/TaskHeritableStorage.jl | 3ecb11693d45c48007de2c15aefc461f53ea9138 | [
"MIT"
] | 2 | 2020-02-08T11:36:00.000Z | 2021-04-17T19:41:56.000Z | module MultiTestRuntests #end
using TaskHeritableStorage
# Test the behavior in MultiTest.jl to override Test.@testset to track nested parallel tests
# NOTE: This overrides the behavior of Test functions
include("../examples/MultiTest.jl")
using Test
#using Testy.JuliaTestModified
@testset "" begin
@test true
e... | 23.076923 | 92 | 0.523333 | [
"@testset \"\" begin\n @test true\nend",
"@static if VERSION >= v\"1.3-\"\n @show Threads.nthreads()\n\n # Test that Testsets now work correctly across multiple threads\n @testset \"outerest\" begin\n @testset \"outerer$i\" for i in 1:3\n t = @testset \"outer\" begin\n @sync beg... |
03528407ef6761326847dc8e784d4a22a24b0176 | 2,336 | jl | Julia | test/testexpmatrices.jl | vissarion/HOODESolver.jl | cabc5b036c94f23a05a338c6dfc86c45982a8e24 | [
"MIT"
] | 5 | 2020-12-14T08:35:27.000Z | 2022-02-17T19:53:27.000Z | test/testexpmatrices.jl | vissarion/HOODESolver.jl | cabc5b036c94f23a05a338c6dfc86c45982a8e24 | [
"MIT"
] | 12 | 2020-12-20T10:57:39.000Z | 2021-06-03T07:36:44.000Z | test/testexpmatrices.jl | vissarion/HOODESolver.jl | cabc5b036c94f23a05a338c6dfc86c45982a8e24 | [
"MIT"
] | 3 | 2021-01-15T15:29:02.000Z | 2021-05-14T13:35:09.000Z | using HOODESolver: _expmat0, _expmat1
using LinearAlgebra
using Random
using SparseArrays
using Test
@testset "Exponential matrices" begin
A=zeros(Int64, 4, 4)
A[1,3] = 1
A[3,1] = -1
@time @testset "test 1 exp big matrices" begin
@test isapprox( one(A), _expmat1(0A), atol=1e-16)
@test ... | 34.865672 | 93 | 0.504709 | [
"@testset \"Exponential matrices\" begin\n\n A=zeros(Int64, 4, 4)\n A[1,3] = 1\n A[3,1] = -1\n @time @testset \"test 1 exp big matrices\" begin\n @test isapprox( one(A), _expmat1(0A), atol=1e-16)\n @test isapprox(exp(0.123*A), _expmat1(0.123*A), atol=1e-15)\n end \n @time @testset... |
0353f8b945d9296030bcc8a66ca6014df433da5a | 2,093 | jl | Julia | julia/sorting/test_sorts.jl | blallen/CodePractice | b7bc8684a2fb1c4eff9f57ccfe5d84d86d48cfe5 | [
"MIT"
] | null | null | null | julia/sorting/test_sorts.jl | blallen/CodePractice | b7bc8684a2fb1c4eff9f57ccfe5d84d86d48cfe5 | [
"MIT"
] | null | null | null | julia/sorting/test_sorts.jl | blallen/CodePractice | b7bc8684a2fb1c4eff9f57ccfe5d84d86d48cfe5 | [
"MIT"
] | null | null | null | using Test
include("insertion_sort.jl")
include("selection_sort.jl")
include("merge_sort.jl")
include("heap_sort.jl")
include("quick_sort.jl")
include("counting_sort.jl")
@testset "test sorting correctness" begin
inputs = [
[5 2 4 7 1 3 2 6],
[4 1 3 2 16 9 10 14 8 7],
[2 8 7 1 3 5 6 4],
... | 23.784091 | 51 | 0.494028 | [
"@testset \"test sorting correctness\" begin\n inputs = [\n [5 2 4 7 1 3 2 6],\n [4 1 3 2 16 9 10 14 8 7],\n [2 8 7 1 3 5 6 4],\n [2 5 3 0 2 3 0 3],\n [329 457 657 839 436 720 355],\n ]\n outputs = [\n [1 2 2 3 4 5 6 7],\n [1 2 3 4 7 8 9 10 14 16],\n ... |
0354c3d22fe7e6ba382d8f68dd0bf749597a61b3 | 43,458 | jl | Julia | test/NonlinearFitting.jl | UnofficialJuliaMirrorSnapshots/EquationsOfState.jl-0438fec6-b81c-52d9-9651-d286848f50a8 | 2c5c5cc31810d17d674ea27ac1f88408b10a8400 | [
"MIT"
] | null | null | null | test/NonlinearFitting.jl | UnofficialJuliaMirrorSnapshots/EquationsOfState.jl-0438fec6-b81c-52d9-9651-d286848f50a8 | 2c5c5cc31810d17d674ea27ac1f88408b10a8400 | [
"MIT"
] | null | null | null | test/NonlinearFitting.jl | UnofficialJuliaMirrorSnapshots/EquationsOfState.jl-0438fec6-b81c-52d9-9651-d286848f50a8 | 2c5c5cc31810d17d674ea27ac1f88408b10a8400 | [
"MIT"
] | null | null | null | using Test
using Unitful, UnitfulAtomic
using EquationsOfState
using EquationsOfState.Collections
using EquationsOfState.NonlinearFitting
@testset "Test fitting energy with different element types" begin
result = BirchMurnaghan3rd(
0.0057009512119028044,
103.58772269057364,
-144.451524575... | 29.765753 | 292 | 0.520272 | [
"@testset \"Test fitting energy with different element types\" begin\n result = BirchMurnaghan3rd(\n 0.0057009512119028044,\n 103.58772269057364,\n -144.45152457521132,\n -40.31992619868024,\n ) |> Collections.fieldvalues\n @test isapprox(\n lsqfit(\n EnergyFor... |
03566d07a27726db52f6788f5d8df2fecd448f24 | 95 | jl | Julia | test/runtests.jl | Anastasgrek/Cryptoworld.jl | 6f51f3d05df29be4c4ff4be80ea5234abdd38bb2 | [
"MIT"
] | null | null | null | test/runtests.jl | Anastasgrek/Cryptoworld.jl | 6f51f3d05df29be4c4ff4be80ea5234abdd38bb2 | [
"MIT"
] | null | null | null | test/runtests.jl | Anastasgrek/Cryptoworld.jl | 6f51f3d05df29be4c4ff4be80ea5234abdd38bb2 | [
"MIT"
] | null | null | null | using Cryptoworld
using Test
@testset "Cryptoworld.jl" begin
# Write your tests here.
end
| 13.571429 | 31 | 0.747368 | [
"@testset \"Cryptoworld.jl\" begin\n # Write your tests here.\nend"
] |
0358274e2c5b2113bad5d2ba6d7565d459c854da | 1,059 | jl | Julia | test/test_dgmulti_1d.jl | thomasgibson/Trixi.jl | 7a7d29045d608a64c397f415bf62e0ebc0f8cf47 | [
"MIT"
] | null | null | null | test/test_dgmulti_1d.jl | thomasgibson/Trixi.jl | 7a7d29045d608a64c397f415bf62e0ebc0f8cf47 | [
"MIT"
] | null | null | null | test/test_dgmulti_1d.jl | thomasgibson/Trixi.jl | 7a7d29045d608a64c397f415bf62e0ebc0f8cf47 | [
"MIT"
] | null | null | null | module TestExamplesDGMulti1D
using Test
using Trixi
include("test_trixi.jl")
EXAMPLES_DIR = joinpath(examples_dir(), "dgmulti_1d")
# Start with a clean environment: remove Trixi output directory if it exists
outdir = "out"
isdir(outdir) && rm(outdir, recursive=true)
@testset "DGMulti 1D" begin
@trixi_testset "el... | 31.147059 | 112 | 0.75543 | [
"@testset \"DGMulti 1D\" begin\n @trixi_testset \"elixir_euler_flux_diff.jl \" begin\n @test_trixi_include(joinpath(EXAMPLES_DIR, \"elixir_euler_flux_diff.jl\"),\n cells_per_dimension = (16,),\n l2 = [7.853842541289665e-7, 9.609905503440606e-7, 2.832322219966481e-6],\n linf = [1.5003758788711963e... |
0359ba30aaa97dc114faeb2b755da80070da9902 | 12,393 | jl | Julia | test/runtests.jl | kunzaatko/Query.jl | e36d8af8aaec4673846a24ffb9bf68fbf5edf02c | [
"MIT"
] | 264 | 2018-08-07T12:52:40.000Z | 2022-03-18T22:44:36.000Z | test/runtests.jl | kunzaatko/Query.jl | e36d8af8aaec4673846a24ffb9bf68fbf5edf02c | [
"MIT"
] | 138 | 2018-07-26T19:32:58.000Z | 2021-09-07T11:54:17.000Z | test/runtests.jl | kunzaatko/Query.jl | e36d8af8aaec4673846a24ffb9bf68fbf5edf02c | [
"MIT"
] | 43 | 2018-07-28T08:48:42.000Z | 2021-12-29T00:07:16.000Z | using Query
using QueryOperators
using DataFrames
using DataValues
using Documenter
using Test
struct Person
Name::String
Friends::Vector{String}
end
@testset "Queries" begin
@testset "Utilities" begin
@test !Query.ismacro(Symbol("@from"), "@from")
@test !Query.ismacro(:(a == 1), "@from")... | 24.492095 | 120 | 0.609538 | [
"@testset \"Queries\" begin\n\n @testset \"Utilities\" begin\n @test !Query.ismacro(Symbol(\"@from\"), \"@from\")\n @test !Query.ismacro(:(a == 1), \"@from\")\n @test Query.ismacro(:(@from 1), \"@from\")\n @test Query.ismacro(:(@from(1)), \"@from\")\n @test !Query.ismacro(:(@fr... |
035b8520ca93726766448c3c51de3435b744493d | 480 | jl | Julia | test/runtests.jl | sylvaticus/QuizQuestions.jl | 27b35af704429264b44c1fe2a653ab7fb0ffa9c5 | [
"MIT"
] | null | null | null | test/runtests.jl | sylvaticus/QuizQuestions.jl | 27b35af704429264b44c1fe2a653ab7fb0ffa9c5 | [
"MIT"
] | null | null | null | test/runtests.jl | sylvaticus/QuizQuestions.jl | 27b35af704429264b44c1fe2a653ab7fb0ffa9c5 | [
"MIT"
] | null | null | null | using QuizQuestions
using Test
@testset "QuizQuestions.jl" begin
@test numericq(1).tol == 0
@test numericq(1, 1e-3; hint="hint").hint == "hint"
@test stringq(r"abc").re == r"abc"
@test_throws MethodError stringq("abc") # need regular expression
@test radioq(["one","two", "three"], 1, keep_order=t... | 30 | 83 | 0.629167 | [
"@testset \"QuizQuestions.jl\" begin\n @test numericq(1).tol == 0\n @test numericq(1, 1e-3; hint=\"hint\").hint == \"hint\"\n\n @test stringq(r\"abc\").re == r\"abc\"\n @test_throws MethodError stringq(\"abc\") # need regular expression\n\n @test radioq([\"one\",\"two\", \"three\"], 1, keep_order=tru... |
035c291b4be8f8ba5df36c63e58d94f2cc80ae12 | 31,489 | jl | Julia | test/compiler/inline.jl | nickrobinson251/julia | 50645289cf008f77d8984e009e376a2a9e2b297a | [
"MIT"
] | null | null | null | test/compiler/inline.jl | nickrobinson251/julia | 50645289cf008f77d8984e009e376a2a9e2b297a | [
"MIT"
] | 150 | 2021-10-01T19:36:29.000Z | 2021-12-28T23:04:20.000Z | test/compiler/inline.jl | nickrobinson251/julia | 50645289cf008f77d8984e009e376a2a9e2b297a | [
"MIT"
] | null | null | null | # This file is a part of Julia. License is MIT: https://julialang.org/license
using Test
using Base.Meta
using Core: ReturnNode
"""
Helper to walk the AST and call a function on every node.
"""
function walk(func, expr)
func(expr)
if isa(expr, Expr)
func(expr.head)
for o in expr.args
... | 35.500564 | 139 | 0.647083 | [
"@testset \"issue #19122: [no]inline of short func. def. with return type annotation\" begin\n exf19122 = @macroexpand(@inline f19122()::Bool = true)\n exg19122 = @macroexpand(@noinline g19122()::Bool = true)\n @test exf19122.args[2].args[1].args[1] == :inline\n @test exg19122.args[2].args[1].args[1] ==... |
035dbab5ca27eb0ac247642c416e2f7dbfa71e3d | 298 | jl | Julia | test/phase_vocoder.jl | JeffFessler/Sound.jl | dd9177669e81b74bf5c3e85fb23ac41bd45af4c8 | [
"MIT"
] | 7 | 2021-11-27T13:53:36.000Z | 2021-12-09T19:55:57.000Z | test/phase_vocoder.jl | JeffFessler/Sound.jl | dd9177669e81b74bf5c3e85fb23ac41bd45af4c8 | [
"MIT"
] | 15 | 2021-11-27T13:44:40.000Z | 2022-03-14T19:26:46.000Z | test/phase_vocoder.jl | JeffFessler/Sound.jl | dd9177669e81b74bf5c3e85fb23ac41bd45af4c8 | [
"MIT"
] | 1 | 2021-12-02T12:33:00.000Z | 2021-12-02T12:33:00.000Z | # phase_vocoder.jl
using Sound: phase_vocoder
using Test: @testset, @test, @inferred
@testset "vocoder" begin
S = 8192
N = S
x = cos.(2π*400*(1:N)/S)
y = @inferred phase_vocoder(x, S)
@test length(y) == 2N
y2 = @inferred phase_vocoder([x 2x], S)
@test y2 ≈ [y 2y]
end
| 19.866667 | 43 | 0.604027 | [
"@testset \"vocoder\" begin\n S = 8192\n N = S\n x = cos.(2π*400*(1:N)/S)\n y = @inferred phase_vocoder(x, S)\n @test length(y) == 2N\n y2 = @inferred phase_vocoder([x 2x], S)\n @test y2 ≈ [y 2y]\nend"
] |
036351cdb73128fadea5b01095e48ad5a8ec7cac | 9,803 | jl | Julia | test/doctests/doctests.jl | rikhuijzer/Documenter.jl | cacf739b425b088e285af14a214cf4865bfb0019 | [
"MIT"
] | 1 | 2021-01-18T18:26:40.000Z | 2021-01-18T18:26:40.000Z | test/doctests/doctests.jl | rikhuijzer/Documenter.jl | cacf739b425b088e285af14a214cf4865bfb0019 | [
"MIT"
] | 1 | 2019-08-19T04:19:22.000Z | 2019-08-19T04:19:22.000Z | test/doctests/doctests.jl | rikhuijzer/Documenter.jl | cacf739b425b088e285af14a214cf4865bfb0019 | [
"MIT"
] | 1 | 2016-06-07T04:27:31.000Z | 2016-06-07T04:27:31.000Z | # To fix all the output reference, run this file with
#
# DOCUMENTER_FIXTESTS= julia doctests.jl
#
# If the inputs and outputs are giving you trouble, you can run the tests with
#
# JULIA_DEBUG=DocTestsTests julia doctests.jl
#
# TODO: Combine the makedocs calls and stdout files. Also, allow running them one by o... | 38.292969 | 122 | 0.617566 | [
"@testset \"doctesting\" begin\n # So, we have 4 doctests: 2 in a docstring, 2 in an .md file. One of either pair is\n # OK, other is broken. Here we first test all possible combinations of these doctest\n # with strict = true to make sure that the doctests are indeed failing.\n #\n # Some tests are ... |
036373beade264b0b82d9dd447238894cc935125 | 430 | jl | Julia | test/runtests.jl | jfbarthelemy/Tensors.jl | 237addc4805cfeb6f669779de62b00d890130cda | [
"BSL-1.0"
] | 94 | 2017-02-09T12:23:05.000Z | 2021-02-16T10:57:53.000Z | test/runtests.jl | wangleiphy/Tensors.jl | 0a881a8e1739184a0acc3a153f204460588a4746 | [
"BSL-1.0"
] | 121 | 2017-02-09T13:02:58.000Z | 2021-01-18T14:22:10.000Z | test/runtests.jl | wangleiphy/Tensors.jl | 0a881a8e1739184a0acc3a153f204460588a4746 | [
"BSL-1.0"
] | 21 | 2017-02-09T13:04:13.000Z | 2021-02-16T10:57:55.000Z | using Tensors
using Test
using TimerOutputs
using LinearAlgebra
using Random
using Statistics: mean
macro testsection(str, block)
return quote
@timeit "$($(esc(str)))" begin
@testset "$($(esc(str)))" begin
$(esc(block))
end
end
end
end
reset_timer!()
in... | 15.925926 | 43 | 0.623256 | [
"@timeit \"$($(esc(str)))\" begin\n @testset \"$($(esc(str)))\" begin\n $(esc(block))\n end\n end"
] |
0363a33d2c9649485e1bc3cba10bf54696496ed0 | 3,425 | jl | Julia | test/runtests.jl | glwagner/OceanLES.jl | f96b6bb0dd76aad6b4e600617d4f14c71afddefc | [
"MIT"
] | 1 | 2019-05-02T18:14:01.000Z | 2019-05-02T18:14:01.000Z | test/runtests.jl | glwagner/Oceananigans.jl | f96b6bb0dd76aad6b4e600617d4f14c71afddefc | [
"MIT"
] | null | null | null | test/runtests.jl | glwagner/Oceananigans.jl | f96b6bb0dd76aad6b4e600617d4f14c71afddefc | [
"MIT"
] | null | null | null | using Test
using Printf
using Random
using Statistics
using LinearAlgebra
using Logging
using JLD2
using FFTW
using OffsetArrays
using Oceananigans.Architectures: @hascuda
@hascuda begin
import CUDAdrv
using CuArrays
using CUDAnative
end
using Oceananigans
using Oceananigans.Architectures
using Oceananig... | 25.94697 | 113 | 0.722628 | [
"@testset \"Oceananigans\" begin\n include(\"test_grids.jl\")\n include(\"test_fields.jl\")\n include(\"test_halo_regions.jl\")\n include(\"test_operators.jl\")\n include(\"test_solvers.jl\")\n include(\"test_pressure_solvers.jl\")\n include(\"test_coriolis.jl\")\n ... |
03675df9de3fd9206290eff7a4b1524cac22472c | 207 | jl | Julia | test/runtests.jl | numlinalg/RLinearAlgebra.jl | 757cc7e581303c4fb6db228618f4be5caa02d3b0 | [
"MIT"
] | 7 | 2021-05-28T17:10:14.000Z | 2022-03-17T05:23:14.000Z | test/runtests.jl | numlinalg/RLinearAlgebra.jl | 757cc7e581303c4fb6db228618f4be5caa02d3b0 | [
"MIT"
] | 7 | 2021-06-16T16:01:29.000Z | 2021-08-16T12:28:20.000Z | test/runtests.jl | numlinalg/RLinearAlgebra.jl | 757cc7e581303c4fb6db228618f4be5caa02d3b0 | [
"MIT"
] | null | null | null | # This file is part of RLinearAlgebra.jl
using Test
@testset verbose=true "RLinearAlbera.jl" begin
for file in readlines(joinpath(@__DIR__, "testgroups.txt"))
include(file * ".jl")
end
end
| 20.7 | 63 | 0.695652 | [
"@testset verbose=true \"RLinearAlbera.jl\" begin\n for file in readlines(joinpath(@__DIR__, \"testgroups.txt\"))\n include(file * \".jl\")\n end\nend"
] |
03682419a82e9c0d0ec32ad844e3ad54479a0f2a | 14,783 | jl | Julia | test/runtests.jl | sethaxen/StatsMakie.jl | d52f20d23fdc4f4a82624f44dd4465442027b759 | [
"MIT"
] | null | null | null | test/runtests.jl | sethaxen/StatsMakie.jl | d52f20d23fdc4f4a82624f44dd4465442027b759 | [
"MIT"
] | null | null | null | test/runtests.jl | sethaxen/StatsMakie.jl | d52f20d23fdc4f4a82624f44dd4465442027b759 | [
"MIT"
] | null | null | null | using AbstractPlotting, StatsMakie, StatsBase
using Test
using Random: seed!
using AbstractPlotting.GeometryTypes: HyperRectangle
using Distributions
using KernelDensity: kde
seed!(0)
@testset "boxplot" begin
a = repeat(1:5, inner = 20)
b = 1:100
p = boxplot(a, b)
plts = p[end].plots
@test length... | 32.705752 | 219 | 0.515119 | [
"@testset \"boxplot\" begin\n a = repeat(1:5, inner = 20)\n b = 1:100\n p = boxplot(a, b)\n plts = p[end].plots\n @test length(plts) == 4\n @test plts[1] isa Scatter\n @test isempty(plts[1][1][])\n\n @test plts[2] isa LineSegments\n pts = Point{2, Float32}[\n [1.0, 5.75], [1.0, 1.0... |
036845433106bde64f206402675c32b18534ae95 | 97 | jl | Julia | test/runtests.jl | simonschoelly/GraphKernels.jl | f04797de0b86a39172b6adbcfcee35ec4b39f91b | [
"MIT"
] | 2 | 2021-09-03T10:09:48.000Z | 2021-11-10T00:21:35.000Z | test/runtests.jl | simonschoelly/GraphKernels.jl | f04797de0b86a39172b6adbcfcee35ec4b39f91b | [
"MIT"
] | 1 | 2021-04-08T20:38:47.000Z | 2021-06-24T13:49:39.000Z | test/runtests.jl | simonschoelly/GraphKernels.jl | f04797de0b86a39172b6adbcfcee35ec4b39f91b | [
"MIT"
] | null | null | null | using GraphKernels
using Test
@testset "GraphKernels.jl" begin
# Write your tests here.
end
| 13.857143 | 32 | 0.752577 | [
"@testset \"GraphKernels.jl\" begin\n # Write your tests here.\nend"
] |
0368f9f8e7a1806e6df4b69c6b38a6ae80383c7f | 6,125 | jl | Julia | stdlib/Dates/test/conversions.jl | djsegal/julia-fork | dd3d14e5e7d24985cba6185e2d07a62ee9943d4e | [
"Zlib"
] | 1 | 2020-09-24T09:57:01.000Z | 2020-09-24T09:57:01.000Z | stdlib/Dates/test/conversions.jl | djsegal/julia-fork | dd3d14e5e7d24985cba6185e2d07a62ee9943d4e | [
"Zlib"
] | null | null | null | stdlib/Dates/test/conversions.jl | djsegal/julia-fork | dd3d14e5e7d24985cba6185e2d07a62ee9943d4e | [
"Zlib"
] | 2 | 2018-10-05T13:57:22.000Z | 2020-09-24T09:57:20.000Z | # This file is a part of Julia. License is MIT: https://julialang.org/license
module ConversionTests
using Test
using Dates
@testset "conversion to/from UNIX" begin
# Test conversion to and from unix
@test Dates.unix2datetime(Dates.datetime2unix(DateTime(2000, 1, 1))) == DateTime(2000, 1, 1)
@test Dates.... | 48.228346 | 181 | 0.661714 | [
"@testset \"conversion to/from UNIX\" begin\n # Test conversion to and from unix\n @test Dates.unix2datetime(Dates.datetime2unix(DateTime(2000, 1, 1))) == DateTime(2000, 1, 1)\n @test Dates.value(Dates.DateTime(1970)) == Dates.UNIXEPOCH\n\n # Tests from here: https://en.wikipedia.org/wiki/Unix_time\n ... |
0369092b99a6f2cc5e154ffad67923b6fd1262bf | 95 | jl | Julia | test/runtests.jl | EvoArt/Cooccurence.jl | 48f8fd588b47daee7502dce3ae9492feb6c03eeb | [
"MIT"
] | null | null | null | test/runtests.jl | EvoArt/Cooccurence.jl | 48f8fd588b47daee7502dce3ae9492feb6c03eeb | [
"MIT"
] | null | null | null | test/runtests.jl | EvoArt/Cooccurence.jl | 48f8fd588b47daee7502dce3ae9492feb6c03eeb | [
"MIT"
] | null | null | null | using Cooccurence
using Test
@testset "Cooccurence.jl" begin
# Write your tests here.
end
| 13.571429 | 31 | 0.747368 | [
"@testset \"Cooccurence.jl\" begin\n # Write your tests here.\nend"
] |
036a58519241356c7cf08ccddaacd7cbf3c07e15 | 2,764 | jl | Julia | test/docsystem.jl | invenia/Documenter.jl | 3e4010db7abbd1e761a66f9b6ccc4435b35a820a | [
"MIT"
] | null | null | null | test/docsystem.jl | invenia/Documenter.jl | 3e4010db7abbd1e761a66f9b6ccc4435b35a820a | [
"MIT"
] | null | null | null | test/docsystem.jl | invenia/Documenter.jl | 3e4010db7abbd1e761a66f9b6ccc4435b35a820a | [
"MIT"
] | null | null | null | module DocSystemTests
using Test
using Compat
import Documenter: Documenter, DocSystem
const alias_of_getdocs = DocSystem.getdocs # NOTE: won't get docstrings if in a @testset
PACKAGES_LOADED_MAIN = VERSION < v"0.7.0-DEV.1877"
@testset "DocSystem" begin
## Bindings.
@test_throws ArgumentError DocSystem.bin... | 32.904762 | 99 | 0.604197 | [
"@testset \"DocSystem\" begin\n ## Bindings.\n @test_throws ArgumentError DocSystem.binding(9000)\n let b = Docs.Binding(@__MODULE__, :DocSystem)\n @test DocSystem.binding(b) == b\n end\n let b = DocSystem.binding(Documenter.Documents.Document)\n @test b.mod === Documenter.Documents\n ... |
036c6f83733ee2a498eaaf33a444d286087386eb | 1,226 | jl | Julia | test/bzmesh_symmetry.jl | epolack/DFTK.jl | 7256a356c9870aee350fbf181f10de8f4d83f592 | [
"MIT"
] | 9 | 2019-05-16T13:05:19.000Z | 2019-10-05T13:56:46.000Z | test/bzmesh_symmetry.jl | epolack/DFTK.jl | 7256a356c9870aee350fbf181f10de8f4d83f592 | [
"MIT"
] | 35 | 2019-06-14T08:08:45.000Z | 2019-11-09T13:46:54.000Z | test/bzmesh_symmetry.jl | epolack/DFTK.jl | 7256a356c9870aee350fbf181f10de8f4d83f592 | [
"MIT"
] | 2 | 2019-07-19T07:38:49.000Z | 2019-10-15T09:48:05.000Z | using DFTK
using Test
include("testcases.jl")
@testset "Symmetrization and not symmetrization yields the same density and energy" begin
args = ((kgrid=[2, 2, 2], kshift=[1/2, 0, 0]),
(kgrid=[2, 2, 2], kshift=[1/2, 1/2, 0]),
(kgrid=[2, 2, 2], kshift=[0, 0, 0]),
(kgrid=[3, 2, 3], ... | 38.3125 | 93 | 0.601142 | [
"@testset \"Symmetrization and not symmetrization yields the same density and energy\" begin\n args = ((kgrid=[2, 2, 2], kshift=[1/2, 0, 0]),\n (kgrid=[2, 2, 2], kshift=[1/2, 1/2, 0]),\n (kgrid=[2, 2, 2], kshift=[0, 0, 0]),\n (kgrid=[3, 2, 3], kshift=[0, 0, 0]),\n (kgr... |
036cb45c526a4ca6fe4444d5804907bdb7a26d60 | 11,201 | jl | Julia | test/utils.jl | guilhermebodin/DiffOpt.jl | b2284192260f6a0fc8ce853eea47728ed1ab59d1 | [
"MIT"
] | null | null | null | test/utils.jl | guilhermebodin/DiffOpt.jl | b2284192260f6a0fc8ce853eea47728ed1ab59d1 | [
"MIT"
] | null | null | null | test/utils.jl | guilhermebodin/DiffOpt.jl | b2284192260f6a0fc8ce853eea47728ed1ab59d1 | [
"MIT"
] | null | null | null | using Test
using JuMP
import DiffOpt
import MathOptInterface
const MOI = MathOptInterface
import LinearAlgebra: dot, ⋅, Diagonal
import SparseArrays: sparse
macro _test(computed, expected::Symbol)
exp = esc(expected)
com = esc(computed)
ato = esc(:atol)
rto = esc(:rtol)
return :(
if $exp ==... | 31.552113 | 205 | 0.544684 | [
"@testset \"Backward pass\" begin\n MOI.set.(model, DiffOpt.BackwardInVariablePrimal(), v, dzb)\n\n DiffOpt.backward(model)\n\n dobjb = MOI.get(model, DiffOpt.BackwardOutObjective())\n spb = DiffOpt.sparse_array_representation(\n DiffOpt.standard_form(dobjb),\n n,\n... |
037414888e0410802d915152249fe70cbd78cfc2 | 3,228 | jl | Julia | test/MoreAnalysis.jl | lucifer1004/Pluto.jl | bfa99933273e8b6b989759db17e114b2f9879559 | [
"MIT"
] | 1 | 2022-02-04T11:58:15.000Z | 2022-02-04T11:58:15.000Z | test/MoreAnalysis.jl | lucifer1004/Pluto.jl | bfa99933273e8b6b989759db17e114b2f9879559 | [
"MIT"
] | 1 | 2022-02-28T12:50:51.000Z | 2022-02-28T12:50:51.000Z | test/MoreAnalysis.jl | lucifer1004/Pluto.jl | bfa99933273e8b6b989759db17e114b2f9879559 | [
"MIT"
] | null | null | null | import Pluto: Pluto, Cell
import Pluto.MoreAnalysis
using Test
@testset "MoreAnalysis" begin
file = joinpath(@__DIR__, "parallelpaths4.jl")
newpath = tempname()
Pluto.readwrite(file, newpath)
notebook = Pluto.load_notebook(newpath)
# Run pluto's analysis. This is like opening the notebook, with... | 41.922078 | 128 | 0.614932 | [
"@testset \"MoreAnalysis\" begin\n\n file = joinpath(@__DIR__, \"parallelpaths4.jl\")\n\n newpath = tempname()\n Pluto.readwrite(file, newpath)\n\n notebook = Pluto.load_notebook(newpath)\n # Run pluto's analysis. This is like opening the notebook, without actually running it\n # s = Pluto.ServerS... |
0378916f2deea392aad6f71a6c63125054162eeb | 9,721 | jl | Julia | generators/GeneratorUtils/src/GeneratorUtils.jl | ee7/julia | 8ea1a08503d6ee9480655039d45ca02c43d85dd0 | [
"MIT"
] | 42 | 2017-06-27T01:08:51.000Z | 2022-03-31T08:34:10.000Z | generators/GeneratorUtils/src/GeneratorUtils.jl | ee7/julia | 8ea1a08503d6ee9480655039d45ca02c43d85dd0 | [
"MIT"
] | 269 | 2017-06-19T13:56:09.000Z | 2022-03-11T22:15:18.000Z | generators/GeneratorUtils/src/GeneratorUtils.jl | ee7/julia | 8ea1a08503d6ee9480655039d45ca02c43d85dd0 | [
"MIT"
] | 69 | 2017-06-20T18:47:38.000Z | 2022-03-11T22:15:52.000Z | # See default_template.jl for an example using this module.
module GeneratorUtils
using DataStructures: OrderedDict
using Printf
export camel_to_snake, exercism_format, expects_error, has_override, override!,
print_runtests, tighten
const INDENT = ' '^4
"""
tighten(collection) -> new_collection
Return a n... | 35.608059 | 105 | 0.689847 | [
"@printf(io, \"\"\"@testset \"%s\" begin\\n\"\"\", get_description(case))"
] |
0379c27c91a4eacece763c47ba9a0663084ca136 | 24,620 | jl | Julia | test/timearray.jl | dwinrow/TimeSeries.jl | 0356f4bbad7e7f7b6a8cacde04f0948a65fd4ed4 | [
"MIT"
] | 292 | 2015-01-03T14:40:15.000Z | 2022-03-25T11:41:32.000Z | test/timearray.jl | dwinrow/TimeSeries.jl | 0356f4bbad7e7f7b6a8cacde04f0948a65fd4ed4 | [
"MIT"
] | 344 | 2015-01-25T19:12:03.000Z | 2022-03-24T09:59:44.000Z | test/timearray.jl | dwinrow/TimeSeries.jl | 0356f4bbad7e7f7b6a8cacde04f0948a65fd4ed4 | [
"MIT"
] | 94 | 2015-03-18T19:59:04.000Z | 2022-01-16T01:32:48.000Z | using Dates
using Test
using MarketData
using TimeSeries
@testset "timearray" begin
@testset "field extraction methods work" begin
@testset "timestamp, values, colnames and meta" begin
for ta ∈ [cl, op, ohlc]
@test timestamp(ta) isa Vector{Date}
@test values(ta) isa Array{Fl... | 34.385475 | 141 | 0.506255 | [
"@testset \"timearray\" begin\n\n\n@testset \"field extraction methods work\" begin\n @testset \"timestamp, values, colnames and meta\" begin\n for ta ∈ [cl, op, ohlc]\n @test timestamp(ta) isa Vector{Date}\n @test values(ta) isa Array{Float64}\n @test colnames(ta) isa... |
0382ba3f1bba596bf27b27ca21a6422c66d3379a | 10,589 | jl | Julia | test/snoopi.jl | charleskawczynski/SnoopCompile.jl | d18b72257c18a11229e84e8f3932abe5447386bc | [
"MIT"
] | 202 | 2015-09-18T19:42:27.000Z | 2022-03-31T07:43:00.000Z | test/snoopi.jl | charleskawczynski/SnoopCompile.jl | d18b72257c18a11229e84e8f3932abe5447386bc | [
"MIT"
] | 200 | 2015-09-18T09:02:38.000Z | 2022-03-14T23:40:13.000Z | test/snoopi.jl | charleskawczynski/SnoopCompile.jl | d18b72257c18a11229e84e8f3932abe5447386bc | [
"MIT"
] | 40 | 2015-09-18T08:39:52.000Z | 2022-03-14T10:12:39.000Z | using SnoopCompile
using InteractiveUtils
using Test
const SP = VERSION >= v"1.6.0-DEV.771" ? " " : "" # JuliaLang/julia #37085
push!(LOAD_PATH, joinpath(@__DIR__, "testmodules"))
using A
using E
using FuncKinds
using Reachable.ModuleA
using Reachable.ModuleB
using Reachable2
pop!(LOAD_PATH)
@testset "topmodule" beg... | 36.89547 | 128 | 0.616867 | [
"@testset \"topmodule\" begin\n # topmod is called on moduleroots but nevertheless this is a useful test\n @test SnoopCompile.topmodule([A, A.B]) === A\n @test SnoopCompile.topmodule([A, A.B.C]) === A\n @test SnoopCompile.topmodule([A.B, A]) === A\n @test SnoopCompile.topmodule([A.B.C, A]) === A\n ... |
03833c4478b5c198c41fc18e141a9599be2e8418 | 186 | jl | Julia | test/runtests.jl | tsipenyuk/FPRS | 9cbf7f835ffaed78deb8dd1ca42b5f3bc461c2b3 | [
"MIT"
] | null | null | null | test/runtests.jl | tsipenyuk/FPRS | 9cbf7f835ffaed78deb8dd1ca42b5f3bc461c2b3 | [
"MIT"
] | null | null | null | test/runtests.jl | tsipenyuk/FPRS | 9cbf7f835ffaed78deb8dd1ca42b5f3bc461c2b3 | [
"MIT"
] | null | null | null | using FPRS
using Test
@testset "FPRS.jl" begin
include("test-utilities.jl")
include("test-densities.jl")
include("test-projections.jl")
include("test-loadElser.jl")
end
| 18.6 | 34 | 0.693548 | [
"@testset \"FPRS.jl\" begin\n include(\"test-utilities.jl\")\n include(\"test-densities.jl\")\n include(\"test-projections.jl\")\n include(\"test-loadElser.jl\")\nend"
] |
038441c429ac867bdcf3b0ad06fa93ecaf12a7cc | 38,175 | jl | Julia | test/runtests.jl | UnofficialJuliaMirrorSnapshots/FixedPointDecimals.jl-fb4d412d-6eee-574d-9565-ede6634db7b0 | af3a95ec15caab2c69fb9166dd678cbd6c85c62f | [
"MIT"
] | null | null | null | test/runtests.jl | UnofficialJuliaMirrorSnapshots/FixedPointDecimals.jl-fb4d412d-6eee-574d-9565-ede6634db7b0 | af3a95ec15caab2c69fb9166dd678cbd6c85c62f | [
"MIT"
] | null | null | null | test/runtests.jl | UnofficialJuliaMirrorSnapshots/FixedPointDecimals.jl-fb4d412d-6eee-574d-9565-ede6634db7b0 | af3a95ec15caab2c69fb9166dd678cbd6c85c62f | [
"MIT"
] | null | null | null | using FixedPointDecimals
using FixedPointDecimals: FD, value
using Test
using Printf
using Base.Checked: checked_mul
include("utils.jl")
const SFD2 = FixedDecimal{Int16, 2}
const SFD4 = FixedDecimal{Int16, 4}
const FD1 = FixedDecimal{Int, 1}
const FD2 = FixedDecimal{Int, 2}
const FD3 = FixedDecimal{Int, 3}
const FD4 ... | 37.099125 | 99 | 0.561388 | [
"@testset \"FixedPointDecimals\" begin\n\n# Basic tests for the methods created above\n@testset \"alt\" begin\n @test trunc_alt(FD2, 0.0) == FD2(0)\n @test floor_alt(FD2, 0.0) == FD2(0)\n @test ceil_alt(FD2, 0.0) == FD2(0)\n\n @test trunc_alt(FD2, 2.149) == FD2(2.14)\n @test floor_alt(FD2, 2.149) ==... |
038486bbf43652c61777e9f32c0d214fcbc67dd5 | 97 | jl | Julia | test/runtests.jl | luap-pik/PowerDynIC | 93c89aa5d4fbbe1a5fa048b15444d5afeb3b258a | [
"MIT"
] | null | null | null | test/runtests.jl | luap-pik/PowerDynIC | 93c89aa5d4fbbe1a5fa048b15444d5afeb3b258a | [
"MIT"
] | null | null | null | test/runtests.jl | luap-pik/PowerDynIC | 93c89aa5d4fbbe1a5fa048b15444d5afeb3b258a | [
"MIT"
] | 1 | 2020-05-02T21:23:31.000Z | 2020-05-02T21:23:31.000Z | using PowerDynIC
using Test
@testset "PowerDynIC.jl" begin
# Write your own tests here.
end
| 13.857143 | 32 | 0.742268 | [
"@testset \"PowerDynIC.jl\" begin\n # Write your own tests here.\nend"
] |
0384c95c6c3417c741ed98085e65d4718c429470 | 2,205 | jl | Julia | test/preliminaries.jl | rikhuijzer/PlutoStaticHTML.jl | 04864878bc2a2157a4968fec6d1d942783caeb1c | [
"MIT"
] | 39 | 2021-11-02T15:18:29.000Z | 2022-03-22T11:12:19.000Z | test/preliminaries.jl | rikhuijzer/PlutoStaticHTML.jl | 04864878bc2a2157a4968fec6d1d942783caeb1c | [
"MIT"
] | 54 | 2021-11-04T07:35:00.000Z | 2022-03-27T14:03:00.000Z | test/preliminaries.jl | rikhuijzer/PlutoStaticHTML.jl | 04864878bc2a2157a4968fec6d1d942783caeb1c | [
"MIT"
] | 5 | 2021-11-05T07:23:44.000Z | 2022-03-27T11:00:21.000Z | using DataFrames: DataFrame
using Dates
using PlutoStaticHTML
using Pluto:
Cell,
Notebook,
Pluto,
ServerSession,
SessionActions
using Test
using TimerOutputs: TimerOutput, @timeit
const PKGDIR = string(pkgdir(PlutoStaticHTML))::String
const NOTEBOOK_DIR = joinpath(PKGDIR, "docs", "src", "notebooks"... | 26.890244 | 80 | 0.677098 | [
"@timeit TIMEROUTPUT \"$($(esc(str)))\" begin\n @testset \"$($(esc(str)))\" begin\n $(esc(block))\n end\n end"
] |
038afacfc3ba1ca2c9fa99fcd54bf5633a253740 | 24,849 | jl | Julia | test/sorting.jl | pepijndevos/julia | 3ae25059fb86133b5be456386738045194960f4d | [
"MIT"
] | 1 | 2021-06-22T15:32:49.000Z | 2021-06-22T15:32:49.000Z | test/sorting.jl | pepijndevos/julia | 3ae25059fb86133b5be456386738045194960f4d | [
"MIT"
] | 5 | 2021-10-05T23:11:36.000Z | 2022-03-17T02:49:19.000Z | test/sorting.jl | pepijndevos/julia | 3ae25059fb86133b5be456386738045194960f4d | [
"MIT"
] | 6 | 2020-11-29T23:06:54.000Z | 2021-10-10T23:14:07.000Z | # This file is a part of Julia. License is MIT: https://julialang.org/license
module SortingTests
using Base.Order
using Random
using Test
isdefined(Main, :OffsetArrays) || @eval Main include("testhelpers/OffsetArrays.jl")
using .Main.OffsetArrays
@testset "Order" begin
@test Forward == ForwardOrdering()
@t... | 36.758876 | 117 | 0.519779 | [
"@testset \"Order\" begin\n @test Forward == ForwardOrdering()\n @test ReverseOrdering(Forward) == ReverseOrdering() == Reverse\nend",
"@testset \"midpoint\" begin\n @test Base.Sort.midpoint(1, 3) === 2\n @test Base.Sort.midpoint(2, 4) === 3\n @test 2 <= Base.Sort.midpoint(1, 4) <= 3\n @test Bas... |
038cc378a5cc6635a7ead2c9aa2dd3b230fd793b | 2,031 | jl | Julia | test/conversion.jl | rasmushenningsson/LinearMaps.jl | 752a15714815e67d56c8d5afeb7aec01d186d25f | [
"MIT"
] | null | null | null | test/conversion.jl | rasmushenningsson/LinearMaps.jl | 752a15714815e67d56c8d5afeb7aec01d186d25f | [
"MIT"
] | null | null | null | test/conversion.jl | rasmushenningsson/LinearMaps.jl | 752a15714815e67d56c8d5afeb7aec01d186d25f | [
"MIT"
] | null | null | null | using Test, LinearMaps, LinearAlgebra, SparseArrays, Quaternions
@testset "conversion" begin
A = 2 * rand(ComplexF64, (20, 10)) .- 1
v = rand(ComplexF64, 10)
w = rand(ComplexF64, 20)
V = rand(ComplexF64, 10, 3)
W = rand(ComplexF64, 20, 3)
α = rand()
β = rand()
M = @inferred LinearMap(A)... | 29.867647 | 64 | 0.592811 | [
"@testset \"conversion\" begin\n A = 2 * rand(ComplexF64, (20, 10)) .- 1\n v = rand(ComplexF64, 10)\n w = rand(ComplexF64, 20)\n V = rand(ComplexF64, 10, 3)\n W = rand(ComplexF64, 20, 3)\n α = rand()\n β = rand()\n M = @inferred LinearMap(A)\n N = @inferred LinearMap(M)\n\n @test Matri... |
038d6d14e8efb927f571515a589201fe4445160c | 820 | jl | Julia | test/runtests.jl | bzinberg/Polyhedra.jl | 6ce8dd1fb75f7d4937b280951cef86bc367d6588 | [
"MIT"
] | null | null | null | test/runtests.jl | bzinberg/Polyhedra.jl | 6ce8dd1fb75f7d4937b280951cef86bc367d6588 | [
"MIT"
] | null | null | null | test/runtests.jl | bzinberg/Polyhedra.jl | 6ce8dd1fb75f7d4937b280951cef86bc367d6588 | [
"MIT"
] | null | null | null | using Polyhedra
using SparseArrays
using LinearAlgebra
using Test
using StaticArrays
include("utils.jl")
include("solvers.jl")
include("elements.jl")
include("comp.jl")
include("representation.jl")
include("dimension_names.jl")
include("polyhedron.jl")
include("redundancy.jl")
include("planar.jl")
include("double... | 20 | 76 | 0.745122 | [
"@testset \"Polyhedra tests in $arith arithmetic\" begin\n polyhedratest(Polyhedra.DefaultLibrary{T}(lp_solver), [\"board\"])\n end"
] |
038ef11593e771572bd7f6c2d35ab091c60c4983 | 7,634 | jl | Julia | test/runtests.jl | Yujie-W/NetcdfIO.jl | 015b1b8bd26739721a0c6a0fb0fd9dad9b8ea8ca | [
"Apache-2.0"
] | 1 | 2021-12-30T22:36:35.000Z | 2021-12-30T22:36:35.000Z | test/runtests.jl | Yujie-W/NetcdfIO.jl | 015b1b8bd26739721a0c6a0fb0fd9dad9b8ea8ca | [
"Apache-2.0"
] | 10 | 2021-12-29T06:59:22.000Z | 2022-03-12T00:59:43.000Z | test/runtests.jl | Yujie-W/NetcdfIO.jl | 015b1b8bd26739721a0c6a0fb0fd9dad9b8ea8ca | [
"Apache-2.0"
] | null | null | null | using DataFrames
using NCDatasets
using NetcdfIO
using Test
@testset verbose = true "NetcdfIO Test" begin
@testset "Create" begin
create_nc!("test.nc");
@test true;
create_nc!("test.nc", String["lon", "lat", "ind"], [36, 18, 0]);
@test true;
create_nc!("test.nc", String["lo... | 36.009434 | 111 | 0.504192 | [
"@testset verbose = true \"NetcdfIO Test\" begin\n @testset \"Create\" begin\n create_nc!(\"test.nc\");\n @test true;\n create_nc!(\"test.nc\", String[\"lon\", \"lat\", \"ind\"], [36, 18, 0]);\n @test true;\n create_nc!(\"test.nc\", String[\"lon\", \"lat\", \"ind\"], [36, 18, I... |
03907231a6a747275b7363f058149122b9fe7a7a | 101 | jl | Julia | test/runtests.jl | john-c-davey/FactorMixtures | fff307866ae660aa9ba7af5a5b0088ead8e34cc7 | [
"MIT"
] | null | null | null | test/runtests.jl | john-c-davey/FactorMixtures | fff307866ae660aa9ba7af5a5b0088ead8e34cc7 | [
"MIT"
] | null | null | null | test/runtests.jl | john-c-davey/FactorMixtures | fff307866ae660aa9ba7af5a5b0088ead8e34cc7 | [
"MIT"
] | null | null | null | using FactorMixtures
using Test
@testset "FactorMixtures.jl" begin
# Write your tests here.
end
| 14.428571 | 34 | 0.762376 | [
"@testset \"FactorMixtures.jl\" begin\n # Write your tests here.\nend"
] |
03908c1ebaffe3551ea6959c63a6a0721e463672 | 763 | jl | Julia | test/test_mals.jl | msdupuy/Tensor-Train-Julia | 327545d2e690c40d218d6316b69cf912963591e9 | [
"MIT"
] | 4 | 2021-03-30T11:39:59.000Z | 2022-02-03T10:05:54.000Z | test/test_mals.jl | msdupuy/Tensor-Train-Julia | 327545d2e690c40d218d6316b69cf912963591e9 | [
"MIT"
] | null | null | null | test/test_mals.jl | msdupuy/Tensor-Train-Julia | 327545d2e690c40d218d6316b69cf912963591e9 | [
"MIT"
] | null | null | null | include("discrete_laplacian.jl")
using Test
@testset "MALS linsolv" begin
n = 10
L = Lap(n,3)
b = ones(n,n,n)
x0 = randn(n,n,n)
L_tt = tto_decomp(reshape(L,n,n,n,n,n,n))
b_tt = ttv_decomp(b)
x0_tt = ttv_decomp(x0)
x = L\b[:]
x_tt = mals_linsolv(L_tt,b_tt,x0_tt;tol=0.0)
y = ttv_... | 24.612903 | 62 | 0.614679 | [
"@testset \"MALS linsolv\" begin\n n = 10\n L = Lap(n,3)\n b = ones(n,n,n)\n x0 = randn(n,n,n)\n L_tt = tto_decomp(reshape(L,n,n,n,n,n,n))\n b_tt = ttv_decomp(b)\n x0_tt = ttv_decomp(x0)\n x = L\\b[:]\n x_tt = mals_linsolv(L_tt,b_tt,x0_tt;tol=0.0)\n y = ttv_to_tensor(x_tt)\n @test i... |
039273f8a4dd1ecb3dc2b067f723f50402244b5b | 398 | jl | Julia | test/operations.jl | Rahulub3r/MLJBase.jl | 2e9444d64c6e1f63c0b2be409e1aadb7692672b7 | [
"MIT"
] | 46 | 2021-07-18T23:09:46.000Z | 2022-03-28T04:31:13.000Z | test/operations.jl | Rahulub3r/MLJBase.jl | 2e9444d64c6e1f63c0b2be409e1aadb7692672b7 | [
"MIT"
] | 164 | 2021-06-25T04:39:14.000Z | 2022-03-28T03:32:48.000Z | test/operations.jl | Rahulub3r/MLJBase.jl | 2e9444d64c6e1f63c0b2be409e1aadb7692672b7 | [
"MIT"
] | 10 | 2021-07-22T09:07:21.000Z | 2022-03-08T12:53:48.000Z | module TestOperations
using Test
using MLJBase
using ..Models
@testset "error for operations on nodes" begin
X = rand(4)
m = fit!(machine(UnivariateStandardizer(), X), verbosity=0)
@test_throws ArgumentError inverse_transform(m)
X = source(rand(4))
m = fit!(machine(UnivariateStandardizer(), X), ve... | 20.947368 | 63 | 0.726131 | [
"@testset \"error for operations on nodes\" begin\n X = rand(4)\n m = fit!(machine(UnivariateStandardizer(), X), verbosity=0)\n @test_throws ArgumentError inverse_transform(m)\n X = source(rand(4))\n m = fit!(machine(UnivariateStandardizer(), X), verbosity=0)\n @test_throws ArgumentError inverse_t... |
0395025c7176f5561350a3cf72ce18b8e340d52a | 107 | jl | Julia | test/runtests.jl | JuliaTagBot/ReferenceTraits.jl | 279019f7137d153df128f5e7c93d22e18d4a1f5f | [
"MIT"
] | null | null | null | test/runtests.jl | JuliaTagBot/ReferenceTraits.jl | 279019f7137d153df128f5e7c93d22e18d4a1f5f | [
"MIT"
] | null | null | null | test/runtests.jl | JuliaTagBot/ReferenceTraits.jl | 279019f7137d153df128f5e7c93d22e18d4a1f5f | [
"MIT"
] | null | null | null | using ReferenceTraits
using Test
@testset "ReferenceTraits.jl" begin
# Write your own tests here.
end
| 15.285714 | 35 | 0.766355 | [
"@testset \"ReferenceTraits.jl\" begin\n # Write your own tests here.\nend"
] |
03957a79a55ee9fc919b971a8d437056407b68d2 | 1,522 | jl | Julia | test/runtests.jl | rikhuijzer/InferenceDiagnostics.jl | 13ae88c7ff481d9831b3b09cbe0052658caf4a60 | [
"MIT"
] | 9 | 2021-05-18T09:19:49.000Z | 2021-07-04T21:10:32.000Z | test/runtests.jl | rikhuijzer/InferenceDiagnostics.jl | 13ae88c7ff481d9831b3b09cbe0052658caf4a60 | [
"MIT"
] | 16 | 2021-05-18T12:31:50.000Z | 2021-07-07T01:07:04.000Z | test/runtests.jl | rikhuijzer/InferenceDiagnostics.jl | 13ae88c7ff481d9831b3b09cbe0052658caf4a60 | [
"MIT"
] | 3 | 2021-06-21T19:26:25.000Z | 2021-07-04T18:49:03.000Z | using Pkg
# Activate test environment on older Julia versions
@static if VERSION < v"1.2"
Pkg.activate(@__DIR__)
Pkg.develop(PackageSpec(; path=dirname(@__DIR__)))
Pkg.instantiate()
end
using MCMCDiagnosticTools
using FFTW
using Random
using Statistics
using Test
Random.seed!(1)
@testset "MCMCDiagnosti... | 27.672727 | 87 | 0.64389 | [
"@testset \"MCMCDiagnosticTools.jl\" begin\n @testset \"discrete diagnostic\" begin\n include(\"discretediag.jl\")\n end\n @testset \"ESS\" begin\n include(\"ess.jl\")\n end\n @testset \"Gelman, Rubin and Brooks diagnostic\" begin\n include(\"gelmandiag.jl\")\n end\n @tests... |
0397339a28b7edadd09a61e367b953d6cb49bd22 | 93 | jl | Julia | test/runtests.jl | likanzhan/NeuroPlots.jl | 6599eff71598e33abb49cc2e4b6d272d0980eb45 | [
"MIT"
] | 3 | 2020-05-03T16:37:25.000Z | 2021-09-18T12:21:15.000Z | test/runtests.jl | likanzhan/NeuroPlots.jl | 6599eff71598e33abb49cc2e4b6d272d0980eb45 | [
"MIT"
] | 2 | 2020-03-04T22:10:14.000Z | 2022-02-23T17:48:34.000Z | test/runtests.jl | likanzhan/NeuroPlots.jl | 6599eff71598e33abb49cc2e4b6d272d0980eb45 | [
"MIT"
] | 1 | 2022-01-17T07:30:05.000Z | 2022-01-17T07:30:05.000Z | using NeuroPlots
using Test
@testset "NeuroPlots.jl" begin
# Write your tests here.
end
| 13.285714 | 30 | 0.741935 | [
"@testset \"NeuroPlots.jl\" begin\n # Write your tests here.\nend"
] |
039a2658bec3ce2973c33f561ac11d19004045dd | 103 | jl | Julia | test/runtests.jl | laschuet/RankingDifference.jl | 35f5175bf5b56b25fbf00874b588e4de7d4a3b89 | [
"MIT"
] | 1 | 2020-02-17T13:31:15.000Z | 2020-02-17T13:31:15.000Z | test/runtests.jl | laschuet/RankingDifference.jl | 35f5175bf5b56b25fbf00874b588e4de7d4a3b89 | [
"MIT"
] | null | null | null | test/runtests.jl | laschuet/RankingDifference.jl | 35f5175bf5b56b25fbf00874b588e4de7d4a3b89 | [
"MIT"
] | null | null | null | using RankingDifferences
using Test
@testset "RankingDifferences" begin
include("ranking.jl")
end
| 14.714286 | 35 | 0.786408 | [
"@testset \"RankingDifferences\" begin\n include(\"ranking.jl\")\nend"
] |
039a6f5834d33eefc316d56e368a0fe1364823de | 24,214 | jl | Julia | test/errorshow.jl | ajozefiak/julia | 5dd7636b9033a48853edb5c6b41c06bc3975ecf1 | [
"Zlib"
] | 1 | 2019-07-05T09:45:07.000Z | 2019-07-05T09:45:07.000Z | test/errorshow.jl | AsForMe/julia | d19bb9d4696831fefc374d922ed126333c6f4f1f | [
"Zlib"
] | null | null | null | test/errorshow.jl | AsForMe/julia | d19bb9d4696831fefc374d922ed126333c6f4f1f | [
"Zlib"
] | 1 | 2020-09-08T02:15:32.000Z | 2020-09-08T02:15:32.000Z | # This file is a part of Julia. License is MIT: https://julialang.org/license
using Random, LinearAlgebra
# For curmod_*
include("testenv.jl")
cfile = " at $(@__FILE__):"
c1line = @__LINE__() + 1
method_c1(x::Float64, s::AbstractString...) = true
buf = IOBuffer()
Base.show_method_candidates(buf, Base.MethodError(me... | 42.856637 | 269 | 0.677377 | [
"@testset \"@macroexpand1\" begin\n M = @__MODULE__\n _macroexpand1(ex) = macroexpand(M, ex, recursive=false)\n ex = :(@nest1 42)\n @test _macroexpand1(ex) == macroexpand(M,ex)\n ex = :(@nest2 42)\n @test _macroexpand1(ex) != macroexpand(M,ex)\n @test _macroexpand1(_macroexpand1(ex)) == macroex... |
039a7609276685cd296b2b913221a657fa69073d | 119 | jl | Julia | test/runtests.jl | chengchingwen/Fetch.jl | e474e92a06714fce924933e396cb159071b71bc7 | [
"MIT"
] | 13 | 2021-08-06T09:30:56.000Z | 2022-02-20T03:37:55.000Z | test/runtests.jl | chengchingwen/Fetch.jl | e474e92a06714fce924933e396cb159071b71bc7 | [
"MIT"
] | 5 | 2021-08-11T10:32:16.000Z | 2022-02-20T04:17:46.000Z | test/runtests.jl | chengchingwen/Fetch.jl | e474e92a06714fce924933e396cb159071b71bc7 | [
"MIT"
] | 2 | 2021-08-11T00:20:55.000Z | 2022-02-20T02:43:56.000Z | using Fetch
using Test
using DataDeps
@testset "Fetch.jl" begin
include("gdrive.jl")
include("kaggle.jl")
end
| 13.222222 | 25 | 0.705882 | [
"@testset \"Fetch.jl\" begin\n include(\"gdrive.jl\")\n include(\"kaggle.jl\")\nend"
] |
039c4886f9d1792ad9c09cd8d367463ce3b1630b | 3,696 | jl | Julia | test/runtests.jl | kdayday/PowerSystems.jl | a2994d6df31558b0a822c1577db17cad736c7b74 | [
"BSD-3-Clause"
] | null | null | null | test/runtests.jl | kdayday/PowerSystems.jl | a2994d6df31558b0a822c1577db17cad736c7b74 | [
"BSD-3-Clause"
] | null | null | null | test/runtests.jl | kdayday/PowerSystems.jl | a2994d6df31558b0a822c1577db17cad736c7b74 | [
"BSD-3-Clause"
] | null | null | null | using Test
using Logging
using DataStructures
using Dates
using LinearAlgebra
using PowerSystemCaseBuilder
import TimeSeries
import InteractiveUtils
import JSON3
import PowerSystemCaseBuilder: PSYTestSystems
import InfrastructureSystems
const IS = InfrastructureSystems
using PowerSystems
import PowerSystems: PowerSyste... | 28.651163 | 92 | 0.6875 | [
"@time @testset \"Begin PowerSystems tests\" begin\n @includetests ARGS\n end"
] |
039cd988308115d4d30d39fee6336b4828153049 | 1,479 | jl | Julia | test/lotka_volterra_2d_symmetric_tests.jl | DDMGNI/GeometricProblems.jl | 367f4cf63ff614c3051c7760b835889fdb7a040f | [
"MIT"
] | null | null | null | test/lotka_volterra_2d_symmetric_tests.jl | DDMGNI/GeometricProblems.jl | 367f4cf63ff614c3051c7760b835889fdb7a040f | [
"MIT"
] | 9 | 2020-02-11T01:23:56.000Z | 2020-09-24T11:06:23.000Z | test/lotka_volterra_2d_symmetric_tests.jl | DDMGNI/GeometricProblems.jl | 367f4cf63ff614c3051c7760b835889fdb7a040f | [
"MIT"
] | null | null | null | using SimpleSolvers
using Test
using GeometricIntegrators
using GeometricIntegrators.Integrators.VPRK
using GeometricIntegrators.Utils
using GeometricProblems.LotkaVolterra2dSymmetric
using GeometricProblems.LotkaVolterra2dSymmetric: Δt, nt, reference_solution
SimpleSolvers.set_config(:nls_atol, 8eps())
SimpleSolvers.... | 36.975 | 76 | 0.756592 | [
"@testset \"$(rpad(\"Lotka-Volterra 2D with symmetric Lagrangian\",80))\" begin\n ode = lotka_volterra_2d_ode()\n iode = lotka_volterra_2d_iode()\n idae = lotka_volterra_2d_idae()\n\n int = Integrator(ode, TableauGauss(2), Δt)\n sol = integrate(ode, int, nt)\n @test relative_maximum_error(sol.q, ... |
039da0972e08a5e3d6e0d925fcf474bc9e87c97d | 2,403 | jl | Julia | test/HHL_tests.jl | yezhengkai/QuDiffEq.jl | c79f27d80875c1f1536142598947749d0c6074ec | [
"MIT"
] | 30 | 2019-05-25T11:34:11.000Z | 2021-12-16T04:30:29.000Z | test/HHL_tests.jl | yezhengkai/QuDiffEq.jl | c79f27d80875c1f1536142598947749d0c6074ec | [
"MIT"
] | 19 | 2019-05-30T01:19:42.000Z | 2021-06-29T06:33:21.000Z | test/HHL_tests.jl | yezhengkai/QuDiffEq.jl | c79f27d80875c1f1536142598947749d0c6074ec | [
"MIT"
] | 5 | 2019-07-25T03:31:06.000Z | 2021-06-29T03:40:10.000Z | using Yao
using BitBasis
using QuDiffEq
using Test, LinearAlgebra
function crot(n_reg::Int, C_value::Real)
n_rot = n_reg + 1
rot = chain(n_rot)
θ = zeros(1<<n_reg - 1)
for i = 1:(1<<n_reg - 1)
c_bit = Vector(2:n_rot)
λ = 0.0
for j = 1:n_reg
if (readbit(i,j) == 0)
... | 27.306818 | 104 | 0.564711 | [
"@testset \"HHLCRot\" begin\n hr = HHLCRot{4}([4,3,2], 1, 0.01)\n reg = rand_state(4)\n @test reg |> copy |> hr |> isnormalized\n\n hr2 = crot(3, 0.01)\n reg1 = reg |> copy |> hr\n reg2 = reg |> copy |> hr2\n @test fidelity(reg1, reg2)[] ≈ 1\nend",
"@testset \"HHLtest\" begin\n # Set up in... |
039e60753dc98a1edfec8915c80a79438f1816d9 | 79 | jl | Julia | test/runtests.jl | jzuhone/Ska.jl | 9583429dae8cce6e284d5ede0418b2e2ff0fb68c | [
"MIT"
] | null | null | null | test/runtests.jl | jzuhone/Ska.jl | 9583429dae8cce6e284d5ede0418b2e2ff0fb68c | [
"MIT"
] | null | null | null | test/runtests.jl | jzuhone/Ska.jl | 9583429dae8cce6e284d5ede0418b2e2ff0fb68c | [
"MIT"
] | null | null | null | using Ska
using Test
@testset "Ska.jl" begin
# Write your tests here.
end
| 11.285714 | 28 | 0.696203 | [
"@testset \"Ska.jl\" begin\n # Write your tests here.\nend"
] |
03a479abcdc031bce31c76247b41e87accc41824 | 1,408 | jl | Julia | test/runtests.jl | alan-turing-institute/MLJTuning.jl | b058e8df63ebbd67ef8df823480a42cfd45462b7 | [
"MIT"
] | 41 | 2020-01-28T04:27:57.000Z | 2021-06-11T05:56:59.000Z | test/runtests.jl | alan-turing-institute/MLJTuning.jl | b058e8df63ebbd67ef8df823480a42cfd45462b7 | [
"MIT"
] | 64 | 2020-02-03T21:26:17.000Z | 2021-06-11T03:49:59.000Z | test/runtests.jl | alan-turing-institute/MLJTuning.jl | b058e8df63ebbd67ef8df823480a42cfd45462b7 | [
"MIT"
] | 8 | 2020-02-08T11:38:35.000Z | 2021-05-29T10:25:21.000Z | using Distributed
addprocs(2)
using Test
using MLJTuning
using MLJBase
using StableRNGs
# Display Number of processes and if necessary number
# of Threads
@info "nworkers: $(nworkers())"
@static if VERSION >= v"1.3.0-DEV.573"
@info "nthreads: $(Threads.nthreads())"
else
@info "Running julia $(VERSION). Multit... | 21.333333 | 69 | 0.704545 | [
"@testset \"utilities\" begin\n @test include(\"utilities.jl\")\nend",
"@testset \"selection heuristics\" begin\n include(\"selection_heuristics.jl\")\nend",
"@testset \"tuned_models.jl\" begin\n @test include(\"tuned_models.jl\")\nend",
"@testset \"range_methods\" begin\n @test include(\"range_me... |
03a5cc02387685fcae23f00ed7bff167a51939c1 | 293 | jl | Julia | test/runtests.jl | CiaranOMara/Indexes.jl | 0f82c88c27acf08fccc4afe2c09ef9f6667a4007 | [
"MIT"
] | 2 | 2019-09-09T02:10:22.000Z | 2020-02-16T07:50:44.000Z | test/runtests.jl | CiaranOMara/Indexes.jl | 0f82c88c27acf08fccc4afe2c09ef9f6667a4007 | [
"MIT"
] | 6 | 2020-02-18T09:31:02.000Z | 2021-11-27T12:38:54.000Z | test/runtests.jl | CiaranOMara/Indexes.jl | 0f82c88c27acf08fccc4afe2c09ef9f6667a4007 | [
"MIT"
] | 5 | 2019-09-09T02:11:23.000Z | 2021-06-14T05:52:46.000Z | using Test
using Documenter
using Indexes
@testset "Indexes" begin
# TODO
# @test GenomicFeatures.Indexes.Tabix === GenomicFeatures.Indexes.Tabix
# Include doctests.
DocMeta.setdocmeta!(Indexes, :DocTestSetup, :(using Indexes); recursive=true)
doctest(Indexes; manual = false)
end | 19.533333 | 77 | 0.754266 | [
"@testset \"Indexes\" begin\n # TODO\n # @test GenomicFeatures.Indexes.Tabix === GenomicFeatures.Indexes.Tabix\n\n\n# Include doctests.\nDocMeta.setdocmeta!(Indexes, :DocTestSetup, :(using Indexes); recursive=true)\ndoctest(Indexes; manual = false)\n\nend"
] |
03a6241a048fe76571e46691ba91a9554397c8a7 | 1,466 | jl | Julia | script/verify/multiplicativity-of-siddhu-channel-with-dephrasure.jl | ChitambarLab/CVChannel.jl | 479fa1e70d19b5434137f9017d99830796802d87 | [
"MIT"
] | null | null | null | script/verify/multiplicativity-of-siddhu-channel-with-dephrasure.jl | ChitambarLab/CVChannel.jl | 479fa1e70d19b5434137f9017d99830796802d87 | [
"MIT"
] | 4 | 2021-09-21T00:29:01.000Z | 2021-10-15T00:35:15.000Z | script/verify/multiplicativity-of-siddhu-channel-with-dephrasure.jl | ChitambarLab/cv-channel | 479fa1e70d19b5434137f9017d99830796802d87 | [
"MIT"
] | null | null | null | using CVChannel
using Test
"""
This script shows the Siddhu and dephrasure channels tensored
admit multiplicative communication value.
"""
print("\n Here we verify the multiplicativity of the Siddhu and dephrasure")
print(" channel when ran in parallel. Note as a special")
print(" case this considers the erasure chan... | 31.869565 | 85 | 0.597544 | [
"@testset \"Verifying Multiplicativity of Siddhu Channel with Dephrasure Channel\" begin\n sid_scan_range =[0:0.1:0.5;]\n dephrasure_scan_range = [0:0.1:1;]\n sid_ctr, p_ctr, q_ctr = 1,1,1\n max_val = 0\n is_mult = true\n for s_id in sid_scan_range\n println(\"---Now scanning for s =\", s_i... |
03a70135365be340dd02ab62f34cbe34a2b7fe7a | 310 | jl | Julia | test/runtests.jl | abraemer/XXZNumerics.jl | a54068accd79306e9e2b934b5bf83c4487f64dbb | [
"MIT"
] | 1 | 2022-03-08T17:29:26.000Z | 2022-03-08T17:29:26.000Z | test/runtests.jl | abraemer/XXZNumerics.jl | a54068accd79306e9e2b934b5bf83c4487f64dbb | [
"MIT"
] | 1 | 2021-08-25T06:08:44.000Z | 2021-09-09T11:31:02.000Z | test/runtests.jl | abraemer/XXZNumerics.jl | a54068accd79306e9e2b934b5bf83c4487f64dbb | [
"MIT"
] | null | null | null | using XXZNumerics
using Test, Statistics, Random, LinearAlgebra
@testset "XXZNumerics.jl" begin
# Write your tests here.
include("geometry.jl")
include("interaction.jl")
include("spin_half.jl")
include("entropy.jl")
include("hamiltonian.jl")
include("thermalization.jl")
end
| 16.315789 | 45 | 0.690323 | [
"@testset \"XXZNumerics.jl\" begin\n # Write your tests here.\n include(\"geometry.jl\")\n\n include(\"interaction.jl\")\n\n include(\"spin_half.jl\")\n\n include(\"entropy.jl\")\n\n include(\"hamiltonian.jl\")\n\n include(\"thermalization.jl\")\n\nend"
] |
03aabea6f1d0cd4126749dda70dea4ebb5c83ef4 | 17,141 | jl | Julia | test/2d.jl | dskkato/ImageFiltering.jl | 83ac3ed0a3876479fb8614787a80f7fd1d7ec1c5 | [
"MIT"
] | null | null | null | test/2d.jl | dskkato/ImageFiltering.jl | 83ac3ed0a3876479fb8614787a80f7fd1d7ec1c5 | [
"MIT"
] | null | null | null | test/2d.jl | dskkato/ImageFiltering.jl | 83ac3ed0a3876479fb8614787a80f7fd1d7ec1c5 | [
"MIT"
] | null | null | null | using ImageFiltering, ImageCore, OffsetArrays, FFTViews, ColorVectorSpace, ComputationalResources
using LinearAlgebra
using Test
using ImageFiltering: IdentityUnitRange
using ImageFiltering: borderinstance
@testset "tiling" begin
m = zeros(UInt8, 20, 20)
for i = -2:2; m[diagind(m,i)] .= 0xff; end
kernel = ... | 49.828488 | 155 | 0.579838 | [
"@testset \"tiling\" begin\n m = zeros(UInt8, 20, 20)\n for i = -2:2; m[diagind(m,i)] .= 0xff; end\n kernel = KernelFactors.prewitt((true,true), 1)\n kp = broadcast(*, kernel...)\n # target is the result we want to get\n target = zeros(20, 20)\n dv = [42.5, 85, 85, 42.5]\n for i = 1:4\n ... |
03ab65eee097b73ce76856187a00a0ff6701b842 | 1,351 | jl | Julia | test/accel/broyden.jl | lostella/ProximalAlgorithms.jl | eb978e03d9c9a927ba1dbaae2e4e9aaf9e668a01 | [
"MIT"
] | 68 | 2017-10-19T09:24:20.000Z | 2021-05-11T23:52:28.000Z | test/accel/broyden.jl | lostella/ProximalAlgorithms.jl | eb978e03d9c9a927ba1dbaae2e4e9aaf9e668a01 | [
"MIT"
] | 37 | 2017-12-11T12:12:22.000Z | 2021-03-13T18:40:56.000Z | test/accel/broyden.jl | lostella/ProximalAlgorithms.jl | eb978e03d9c9a927ba1dbaae2e4e9aaf9e668a01 | [
"MIT"
] | 12 | 2017-12-11T09:45:24.000Z | 2021-04-10T12:59:05.000Z | using Test
@testset "Broyden ($R)" for R in [Float32, Float64]
using LinearAlgebra
using ProximalAlgorithms: Broyden, update!
H = R[
0.63287 0.330934 -0.156908 -0.294776 0.10761;
0.330934 0.673201 0.0459778 0.231011 -0.235265;
-0.156908 0.0459778 0.635812 -0... | 21.790323 | 66 | 0.512213 | [
"@testset \"Broyden ($R)\" for R in [Float32, Float64]\n using LinearAlgebra\n using ProximalAlgorithms: Broyden, update!\n\n H = R[\n 0.63287 0.330934 -0.156908 -0.294776 0.10761;\n 0.330934 0.673201 0.0459778 0.231011 -0.235265;\n -0.156908 0.0459778 0.635812 ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.