Skip to content

Commit

Permalink
Updated coverage.
Browse files Browse the repository at this point in the history
  • Loading branch information
janpfeifer committed Jan 20, 2025
1 parent a6ecebf commit ad865bf
Show file tree
Hide file tree
Showing 11 changed files with 41 additions and 37 deletions.
22 changes: 13 additions & 9 deletions docs/coverage.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@ github.com/janpfeifer/gonb/main.go UniqueIDFilter.Filter 100.0%
github.com/janpfeifer/gonb/main.go UniqueIDFilter.FilterF 100.0%
github.com/janpfeifer/gonb/main.go UniqueIDFilter.FilterS 0.0%
github.com/janpfeifer/gonb/main.go SetUpKlog 66.7%
github.com/janpfeifer/gonb/version.go must 50.0%
github.com/janpfeifer/gonb/version.go init 100.0%
github.com/janpfeifer/gonb/cache/cache.go New 75.0%
github.com/janpfeifer/gonb/cache/cache.go AssertNoError 50.0%
github.com/janpfeifer/gonb/cache/cache.go MustNew 100.0%
github.com/janpfeifer/gonb/cache/cache.go NewInTmp 68.2%
github.com/janpfeifer/gonb/cache/cache.go NewInTmp 72.7%
github.com/janpfeifer/gonb/cache/cache.go MustNewInTmp 100.0%
github.com/janpfeifer/gonb/cache/cache.go NewHidden 80.0%
github.com/janpfeifer/gonb/cache/cache.go MustNewHidden 100.0%
Expand Down Expand Up @@ -147,8 +149,8 @@ github.com/janpfeifer/gonb/internal/comms/comms.go New 100.0%
github.com/janpfeifer/gonb/internal/comms/comms.go getFromJson 62.5%
github.com/janpfeifer/gonb/internal/comms/comms.go *State.InstallWebSocket 100.0%
github.com/janpfeifer/gonb/internal/comms/comms.go *State.installWebSocketLocked 79.5%
github.com/janpfeifer/gonb/internal/comms/comms.go *State.HandleOpen 64.4%
github.com/janpfeifer/gonb/internal/comms/comms.go *State.HandleMsg 63.6%
github.com/janpfeifer/gonb/internal/comms/comms.go *State.HandleOpen 68.9%
github.com/janpfeifer/gonb/internal/comms/comms.go *State.HandleMsg 69.7%
github.com/janpfeifer/gonb/internal/comms/comms.go *State.Close 100.0%
github.com/janpfeifer/gonb/internal/comms/comms.go *State.closeLocked 100.0%
github.com/janpfeifer/gonb/internal/comms/comms.go *State.Send 100.0%
Expand All @@ -165,7 +167,7 @@ github.com/janpfeifer/gonb/internal/comms/namedpipes.go *State.ProgramReadValu
github.com/janpfeifer/gonb/internal/comms/namedpipes.go *State.ProgramSubscribeRequest 54.5%
github.com/janpfeifer/gonb/internal/comms/namedpipes.go *State.ProgramUnsubscribeRequest 57.1%
github.com/janpfeifer/gonb/internal/comms/namedpipes.go *State.deliverProgramSubscriptionsLocked 62.5%
github.com/janpfeifer/gonb/internal/dispatcher/comms.go handleComms 55.6%
github.com/janpfeifer/gonb/internal/dispatcher/comms.go handleComms 66.7%
github.com/janpfeifer/gonb/internal/dispatcher/dispatcher.go RunKernel 80.0%
github.com/janpfeifer/gonb/internal/dispatcher/dispatcher.go handleShellMsg 78.4%
github.com/janpfeifer/gonb/internal/dispatcher/dispatcher.go handleBusyMessage 47.8%
Expand All @@ -183,7 +185,8 @@ github.com/janpfeifer/gonb/internal/goexec/composer.go *WriterWithCursor.Write
github.com/janpfeifer/gonb/internal/goexec/composer.go *WriterWithCursor.Write 76.9%
github.com/janpfeifer/gonb/internal/goexec/composer.go *Declarations.RenderImports 100.0%
github.com/janpfeifer/gonb/internal/goexec/composer.go *Declarations.RenderVariables 91.2%
github.com/janpfeifer/gonb/internal/goexec/composer.go *Declarations.RenderFunctions 100.0%
github.com/janpfeifer/gonb/internal/goexec/composer.go *Declarations.RenderFunctions 94.1%
github.com/janpfeifer/gonb/internal/goexec/composer.go *Comments.Render 90.0%
github.com/janpfeifer/gonb/internal/goexec/composer.go *Declarations.RenderTypes 100.0%
github.com/janpfeifer/gonb/internal/goexec/composer.go *Declarations.RenderConstants 100.0%
github.com/janpfeifer/gonb/internal/goexec/composer.go *Constant.Render 100.0%
Expand All @@ -202,7 +205,7 @@ github.com/janpfeifer/gonb/internal/goexec/execcode.go *State.executeCellImpl
github.com/janpfeifer/gonb/internal/goexec/execcode.go *State.PostExecuteCell 85.7%
github.com/janpfeifer/gonb/internal/goexec/execcode.go *State.BinaryPath 100.0%
github.com/janpfeifer/gonb/internal/goexec/execcode.go *State.CodePath 100.0%
github.com/janpfeifer/gonb/internal/goexec/execcode.go *State.RemoveCode 83.3%
github.com/janpfeifer/gonb/internal/goexec/execcode.go *State.RemoveGeneratedCode 83.3%
github.com/janpfeifer/gonb/internal/goexec/execcode.go *State.AlternativeDefinitionsPath 0.0%
github.com/janpfeifer/gonb/internal/goexec/execcode.go *State.Execute 85.7%
github.com/janpfeifer/gonb/internal/goexec/execcode.go *State.Compile 70.0%
Expand Down Expand Up @@ -247,10 +250,11 @@ github.com/janpfeifer/gonb/internal/goexec/inspect.go adjustCursorForFunctionI
github.com/janpfeifer/gonb/internal/goexec/parser.go *parseInfo.getCursor 100.0%
github.com/janpfeifer/gonb/internal/goexec/parser.go *parseInfo.calculateCellLines 100.0%
github.com/janpfeifer/gonb/internal/goexec/parser.go *parseInfo.extractContentOfNode 83.3%
github.com/janpfeifer/gonb/internal/goexec/parser.go *State.parseFromGoCode 79.1%
github.com/janpfeifer/gonb/internal/goexec/parser.go *State.parseFromGoCode 77.3%
github.com/janpfeifer/gonb/internal/goexec/parser.go NewImport 88.9%
github.com/janpfeifer/gonb/internal/goexec/parser.go *parseInfo.ParseImportEntry 100.0%
github.com/janpfeifer/gonb/internal/goexec/parser.go *parseInfo.ParseFuncEntry 100.0%
github.com/janpfeifer/gonb/internal/goexec/parser.go *parseInfo.ParseComments 100.0%
github.com/janpfeifer/gonb/internal/goexec/parser.go *parseInfo.ParseVarEntry 84.6%
github.com/janpfeifer/gonb/internal/goexec/parser.go *parseInfo.ParseConstEntry 100.0%
github.com/janpfeifer/gonb/internal/goexec/parser.go *parseInfo.ParseTypeEntry 100.0%
Expand Down Expand Up @@ -411,11 +415,11 @@ github.com/janpfeifer/gonb/internal/specialcmd/definitions.go removeDefinitionI
github.com/janpfeifer/gonb/internal/specialcmd/definitions.go removeDefinitions 91.7%
github.com/janpfeifer/gonb/internal/specialcmd/specialcmd.go Parse 84.6%
github.com/janpfeifer/gonb/internal/specialcmd/specialcmd.go joinLine 87.5%
github.com/janpfeifer/gonb/internal/specialcmd/specialcmd.go execSpecialConfig 58.2%
github.com/janpfeifer/gonb/internal/specialcmd/specialcmd.go execSpecialConfig 55.1%
github.com/janpfeifer/gonb/internal/specialcmd/specialcmd.go execShell 100.0%
github.com/janpfeifer/gonb/internal/specialcmd/specialcmd.go splitCmd 97.0%
github.com/janpfeifer/gonb/internal/specialcmd/track.go execTrack 27.3%
github.com/janpfeifer/gonb/internal/specialcmd/track.go execUntrack 54.5%
github.com/janpfeifer/gonb/internal/specialcmd/track.go showTrackedList 91.7%
github.com/janpfeifer/gonb/internal/websocket/websocket.go Javascript 83.3%
total (statements) 64.6%
total (statements) 64.8%
4 changes: 2 additions & 2 deletions examples/tests/bash_script.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"name": "stdout",
"output_type": "stream",
"text": [
"/tmp/gonb_d300f5a2\n"
"/tmp/gonb_8e54badc\n"
]
}
],
Expand All @@ -59,7 +59,7 @@
"output_type": "stream",
"text": [
"/home/janpf/Projects/gonb/examples/tests\n",
"/tmp/gonb_d300f5a2\n",
"/tmp/gonb_8e54badc\n",
"/home/janpf/Projects/gonb\n",
"/home/janpf/Projects/gonb\n"
]
Expand Down
4 changes: 2 additions & 2 deletions examples/tests/dom.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
{
"data": {
"text/html": [
"<div id=\"dom.transient_div_25f4f259\"></div>"
"<div id=\"dom.transient_div_77b0e411\"></div>"
]
},
"metadata": {},
Expand Down Expand Up @@ -152,7 +152,7 @@
{
"data": {
"text/html": [
"<div id=\"dom.transient_div_759e5c9b\"></div>"
"<div id=\"dom.transient_div_1889e174\"></div>"
]
},
"metadata": {},
Expand Down
8 changes: 4 additions & 4 deletions examples/tests/goflags.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -153,9 +153,9 @@
"name": "stdout",
"output_type": "stream",
"text": [
"gonb_ae2bcb52/main.go:8:\tA\t\t100.0%\n",
"gonb_ae2bcb52/main.go:12:\tB\t\t0.0%\n",
"gonb_ae2bcb52/main.go:17:\tmain\t\t100.0%\n",
"gonb_a636feef/main.go:8:\tA\t\t100.0%\n",
"gonb_a636feef/main.go:12:\tB\t\t0.0%\n",
"gonb_a636feef/main.go:17:\tmain\t\t100.0%\n",
"total\t\t\t\t(statements)\t75.0%\n"
]
}
Expand Down Expand Up @@ -238,7 +238,7 @@
"name": "stderr",
"output_type": "stream",
"text": [
"# gonb_ae2bcb52\n",
"# gonb_a636feef\n",
"./main.go:10:6: can inline (*Point).ManhattanLen\n",
"./main.go:16:12: inlining call to flag.Parse\n",
"./main.go:18:27: inlining call to (*Point).ManhattanLen\n",
Expand Down
2 changes: 1 addition & 1 deletion examples/tests/gonbui.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"output_type": "stream",
"text": [
"%goflags=[\"--cover\" \"--covermode=set\"]\n",
"GOCOVERDIR=/tmp/gonb_nbtests_gocoverdir_4129479306\n"
"GOCOVERDIR=/tmp/gonb_test_coverage.KXrPgksOg4\n"
]
}
],
Expand Down
12 changes: 6 additions & 6 deletions examples/tests/gotest.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -287,12 +287,12 @@
"text": [
"goos: linux\n",
"goarch: amd64\n",
"pkg: gonb_74e427f6\n",
"pkg: gonb_348f5fd7\n",
"cpu: 12th Gen Intel(R) Core(TM) i9-12900K\n",
"BenchmarkFibonacciA32\n",
"BenchmarkFibonacciA32-24 \t 178\t 6602828 ns/op\n",
"BenchmarkFibonacciA32-24 \t 181\t 6584232 ns/op\n",
"BenchmarkFibonacciB32\n",
"BenchmarkFibonacciB32-24 \t298555876\t 4.021 ns/op\n",
"BenchmarkFibonacciB32-24 \t301803614\t 3.994 ns/op\n",
"PASS\n",
"coverage: [no statements]\n"
]
Expand Down Expand Up @@ -334,10 +334,10 @@
"text": [
"goos: linux\n",
"goarch: amd64\n",
"pkg: gonb_74e427f6\n",
"pkg: gonb_348f5fd7\n",
"cpu: 12th Gen Intel(R) Core(TM) i9-12900K\n",
"BenchmarkFibonacciA32-24 \t 180\t 6574007 ns/op\n",
"BenchmarkFibonacciB32-24 \t308328156\t 3.930 ns/op\n",
"BenchmarkFibonacciA32-24 \t 177\t 6570735 ns/op\n",
"BenchmarkFibonacciB32-24 \t341224015\t 3.960 ns/op\n",
"PASS\n",
"coverage: [no statements]\n"
]
Expand Down
12 changes: 6 additions & 6 deletions examples/tests/gowork.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"name": "stdout",
"output_type": "stream",
"text": [
"/tmp/gonb_tests_gowork_173uIYjd"
"/tmp/gonb_tests_gowork_k5qMEYlN"
]
}
],
Expand Down Expand Up @@ -64,7 +64,7 @@
"name": "stdout",
"output_type": "stream",
"text": [
"Temporary test package: /tmp/gonb_tests_gowork_173uIYjd\n"
"Temporary test package: /tmp/gonb_tests_gowork_k5qMEYlN\n"
]
}
],
Expand Down Expand Up @@ -136,7 +136,7 @@
"name": "stdout",
"output_type": "stream",
"text": [
"\t- Added replace rule for module \"a.com/a/pkg\" to local directory \"/tmp/gonb_tests_gowork_173uIYjd\".\n"
"\t- Added replace rule for module \"a.com/a/pkg\" to local directory \"/tmp/gonb_tests_gowork_k5qMEYlN\".\n"
]
}
],
Expand All @@ -155,7 +155,7 @@
"name": "stdout",
"output_type": "stream",
"text": [
"module gonb_b978d03f\n",
"module gonb_c5afeb93\n",
"\n",
"go 1.23.5\n",
"\n",
Expand Down Expand Up @@ -186,7 +186,7 @@
"text/html": [
"<b>List of files/directories being tracked:</b>\n",
"<ul>\n",
"<li>/tmp/gonb_tests_gowork_173uIYjd</li>\n",
"<li>/tmp/gonb_tests_gowork_k5qMEYlN</li>\n",
"</ul>\n"
]
},
Expand All @@ -208,7 +208,7 @@
"name": "stdout",
"output_type": "stream",
"text": [
"module gonb_b978d03f\n",
"module gonb_c5afeb93\n",
"\n",
"go 1.23.5\n"
]
Expand Down
2 changes: 1 addition & 1 deletion examples/tests/input_boxes.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"output_type": "stream",
"text": [
"%goflags=[\"--cover\" \"--covermode=set\"]\n",
"GOCOVERDIR=/tmp/gonb_nbtests_gocoverdir_4129479306\n"
"GOCOVERDIR=/tmp/gonb_test_coverage.KXrPgksOg4\n"
]
}
],
Expand Down
2 changes: 1 addition & 1 deletion examples/tests/vartuple.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
"text/html": [
"<h4>Variables</h4>\n",
"<ul>\n",
"<li><pre>_~085390</pre></li>\n",
"<li><pre>_~840487</pre></li>\n",
"<li><pre>a</pre></li>\n",
"<li><pre>c</pre></li>\n",
"</ul>"
Expand Down
6 changes: 3 additions & 3 deletions examples/tests/widgets.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@
{
"data": {
"text/html": [
"<div id=\"dom.transient_div_540e2e0c\"></div>"
"<div id=\"dom.transient_div_55acb47e\"></div>"
]
},
"metadata": {},
Expand Down Expand Up @@ -189,7 +189,7 @@
{
"data": {
"text/html": [
"<div id=\"dom.transient_div_ddd43a51\"></div>"
"<div id=\"dom.transient_div_28380cd2\"></div>"
]
},
"metadata": {},
Expand Down Expand Up @@ -304,7 +304,7 @@
{
"data": {
"text/html": [
"<div id=\"dom.transient_div_a322648e\"></div>"
"<div id=\"dom.transient_div_222cc2d0\"></div>"
]
},
"metadata": {},
Expand Down
4 changes: 2 additions & 2 deletions examples/tests/writefile.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"name": "stderr",
"output_type": "stream",
"text": [
"Cell contents written to \"/tmp/gonb_nbtests_writefile_2206415683/poetry.txt\".\n"
"Cell contents written to \"/tmp/gonb_nbtests_writefile_42543885/poetry.txt\".\n"
]
}
],
Expand All @@ -32,7 +32,7 @@
"name": "stderr",
"output_type": "stream",
"text": [
"Cell contents appended to \"/tmp/gonb_nbtests_writefile_2206415683/poetry.txt\".\n"
"Cell contents appended to \"/tmp/gonb_nbtests_writefile_42543885/poetry.txt\".\n"
]
}
],
Expand Down

0 comments on commit ad865bf

Please sign in to comment.