Skip to content

Commit 3fb585d

Browse files
authored
removed expect_silent commented tests and make dev version number (#342)
1 parent 5c792ef commit 3fb585d

File tree

6 files changed

+8
-41
lines changed

6 files changed

+8
-41
lines changed

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Package: pkgnet
22
Type: Package
33
Title: Get Network Representation of an R Package
4-
Version: 0.6.0
4+
Version: 0.6.0.9999
55
Authors@R: c(
66
person("Brian", "Burns", email = "brian.burns.opensource@gmail.com", role = c("aut", "cre")),
77
person("James", "Lamb", email = "jaylamb20@gmail.com", role = c("aut")),

NEWS.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
# development
2+
## NEW FEATURES
3+
4+
## CHANGES
5+
6+
## BUGFIXES
7+
18
# pkgnet 0.6.0
29
## NEW FEATURES
310

tests/testthat/test-DependencyReporter-class.R

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,6 @@ test_that('DependencyReporter works end-to-end for typical use', {
5151
})
5252

5353
## Node and Edge extraction work ##
54-
#expect_silent({testObj$nodes})
55-
#expect_silent({testObj$edges})
56-
5754
expect_true(data.table::is.data.table(testObj$nodes))
5855
expect_true(object = is.element("node", names(testObj$nodes))
5956
, info = "Node column created")
@@ -63,7 +60,6 @@ test_that('DependencyReporter works end-to-end for typical use', {
6360
, info = "TARGET and SOURCE fields in edge table at minimum")
6461

6562
## pkg_graph works ##
66-
#expect_silent({testObj$pkg_graph})
6763
expect_true({"AbstractGraph" %in% class(testObj$pkg_graph)})
6864
expect_true({"DirectedGraph" %in% class(testObj$pkg_graph)})
6965
expect_true({igraph::is_igraph(testObj$pkg_graph$igraph)})
@@ -95,7 +91,6 @@ test_that('DependencyReporter works end-to-end for typical use', {
9591
})
9692

9793
## graph_viz works ##
98-
#expect_silent({testObj$graph_viz})
9994
expect_true(object = is.element("visNetwork", attributes(testObj$graph_viz)))
10095
expect_equivalent(
10196
object = as.data.table(testObj$graph_viz$x$nodes)[, .(id)]

tests/testthat/test-FunctionReporter-class.R

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,6 @@ test_that('FunctionReporter works end-to-end for typical use', {
5959
, info = "$pkg_name did not return expected package name")
6060

6161
## Node and Edge extraction work ##
62-
# expect_silent({
63-
# testObj$nodes
64-
# testObj$edges
65-
# })
66-
6762
expect_true(data.table::is.data.table(testObj$nodes))
6863
expect_true(object = is.element("node", names(testObj$nodes))
6964
, info = "Node column created")
@@ -74,8 +69,6 @@ test_that('FunctionReporter works end-to-end for typical use', {
7469

7570

7671
## pkg_graph works ##
77-
78-
#expect_silent({testObj$pkg_graph})
7972
expect_true({"AbstractGraph" %in% class(testObj$pkg_graph)})
8073
expect_true({"DirectedGraph" %in% class(testObj$pkg_graph)})
8174
expect_true({igraph::is_igraph(testObj$pkg_graph$igraph)})
@@ -118,7 +111,6 @@ test_that('FunctionReporter works end-to-end for typical use', {
118111
)
119112

120113
## graph_viz works ##
121-
#expect_silent({testObj$graph_viz})
122114
expect_true(object = is.element("visNetwork", attributes(testObj$graph_viz)))
123115
expect_equivalent(
124116
object = as.data.table(testObj$graph_viz$x$nodes)[, .(id)]
@@ -136,15 +128,13 @@ test_that('FunctionReporter works end-to-end for typical use', {
136128

137129
test_that('FunctionReporter can directly generate pkg_graph', {
138130
testObj <- FunctionReporter$new()$set_package("baseballstats")
139-
#expect_silent(testObj$pkg_graph)
140131
expect_true("AbstractGraph" %in% class(testObj$pkg_graph))
141132
expect_true(object = igraph::is_igraph(testObj$pkg_graph$igraph)
142133
, info = "Package graph did not successfuly generate igraph object")
143134
})
144135

145136
test_that('FunctionReporter can directly generate graph_viz', {
146137
testObj <- FunctionReporter$new()$set_package("baseballstats")
147-
#expect_silent({testObj$graph_viz})
148138
expect_true(object = is.element("visNetwork", attributes(testObj$graph_viz)))
149139
})
150140

tests/testthat/test-InheritanceReporter-class.R

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -51,11 +51,6 @@ test_that('InheritanceReporter Methods Work', {
5151
})
5252

5353
## Node and Edge extraction work ##
54-
#expect_silent({
55-
# testObj$nodes
56-
# testObj$edges
57-
#})
58-
5954
expect_true(data.table::is.data.table(testObj$nodes))
6055
expect_true(object = is.element("node", names(testObj$nodes))
6156
, info = "Node column created")
@@ -65,7 +60,6 @@ test_that('InheritanceReporter Methods Work', {
6560
, info = "TARGET and SOURCE fields in edge table at minimum")
6661

6762
## pkg_graph works ##
68-
#expect_silent({testObj$pkg_graph})
6963
expect_true({"AbstractGraph" %in% class(testObj$pkg_graph)})
7064
expect_true({"DirectedGraph" %in% class(testObj$pkg_graph)})
7165
expect_true({igraph::is_igraph(testObj$pkg_graph$igraph)})
@@ -97,7 +91,6 @@ test_that('InheritanceReporter Methods Work', {
9791
})
9892

9993
## graph_viz works ##
100-
#expect_silent({testObj$graph_viz})
10194
expect_true(object = is.element("visNetwork", attributes(testObj$graph_viz)))
10295
expect_equivalent(
10396
object = as.data.table(testObj$graph_viz$x$nodes)[, .(id)]

tests/testthat/test-plotting.R

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -16,24 +16,6 @@ test_that('node coloring by discrete and continuous', {
1616
, palette = c("red", "green")
1717
)
1818

19-
#expect_silent({
20-
#
21-
# b$.__enclos_env__$private$set_plot_node_color_scheme(
22-
# field = "filename"
23-
# , palette = c(
24-
# "#E41A1C"
25-
# , "#377EB8"
26-
# , "#4DAF4A"
27-
# , "#984EA3"
28-
# , "#FF7F00"
29-
# , "#FFFF33"
30-
# , "#A65628"
31-
# , "#F781BF"
32-
# , "#999999"
33-
# )
34-
# )
35-
#})
36-
3719
viz <- b$graph_viz
3820
expect_is(viz, "visNetwork")
3921
expect_is(viz, "htmlwidget")

0 commit comments

Comments
 (0)