Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,20 @@ plugins {
}

group 'lv.id.jc'
version '1.0'
version '1.1'

repositories {
mavenCentral()
}

dependencies {
implementation 'org.codehaus.groovy:groovy-all:3.0.9'

// Spock Framework
testImplementation 'org.spockframework:spock-core:2.0-groovy-3.0'
testImplementation 'org.codehaus.groovy:groovy-all:3.0.9'

// Spock Reports
testRuntimeClasspath( "com.athaydes:spock-reports:2.1.1-groovy-3.0" ) {
// transitive = false // this avoids affecting your version of Groovy/Spock
transitive = false // this avoids affecting your version of Groovy/Spock
}
// Required for spock-reports
testImplementation 'org.slf4j:slf4j-api:1.7.32'
Expand Down
Binary file added docs/assets/uml/graph.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
39 changes: 39 additions & 0 deletions docs/assets/uml/graph.uml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<?xml version="1.0" encoding="UTF-8"?>
<Diagram>
<ID>JAVA</ID>
<OriginalElement>lv.id.jc.algorithm.graph</OriginalElement>
<nodes>
<node x="-79.0" y="-132.0">lv.id.jc.algorithm.graph.SearchAlgorithm</node>
<node x="-225.0" y="-19.0">lv.id.jc.algorithm.graph.DijkstrasAlgorithm</node>
<node x="67.0" y="-19.0">lv.id.jc.algorithm.graph.BreadthFirstSearch</node>
<node x="-100.0" y="94.0">lv.id.jc.algorithm.graph.Graph</node>
</nodes>
<notes />
<edges>
<edge source="lv.id.jc.algorithm.graph.BreadthFirstSearch" target="lv.id.jc.algorithm.graph.SearchAlgorithm" relationship="REALIZATION">
<point x="0.0" y="-31.5" />
<point x="203.0" y="-44.0" />
<point x="57.0" y="-44.0" />
<point x="0.0" y="31.5" />
</edge>
<edge source="lv.id.jc.algorithm.graph.DijkstrasAlgorithm" target="lv.id.jc.algorithm.graph.SearchAlgorithm" relationship="REALIZATION">
<point x="0.0" y="-31.5" />
<point x="-89.0" y="-44.0" />
<point x="57.0" y="-44.0" />
<point x="0.0" y="31.5" />
</edge>
</edges>
<settings layout="Hierarchic" zoom="1.0" showDependencies="false" x="282.0" y="181.0" />
<SelectedNodes>
<node>lv.id.jc.algorithm.graph.Graph</node>
</SelectedNodes>
<Categories>
<Category>Fields</Category>
<Category>Inner Classes</Category>
<Category>Methods</Category>
<Category>Properties</Category>
</Categories>
<SCOPE>All</SCOPE>
<VISIBILITY>private</VISIBILITY>
</Diagram>

2 changes: 1 addition & 1 deletion docs/spock-reports/aggregated_report.json

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/spock-reports/graph.BreadthFirstSearchSpec.html
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ <h2>Report for graph.BreadthFirstSearchSpec</h2>
</div>
<div class='summary-report'>
<h3>Summary:</h3>
<div class='date-test-ran'>Created on Mon Jan 03 21:16:51 EET 2022 by jegors.cemisovs</div>
<div class='date-test-ran'>Created on Mon Jan 03 21:28:27 EET 2022 by jegors.cemisovs</div>
<table class='summary-table'>
<thead>
<tr>
Expand All @@ -272,7 +272,7 @@ <h3>Summary:</h3>
<td>0</td>
<td>0</td>
<td>100.0%</td>
<td>0.069 seconds</td>
<td>0.071 seconds</td>
</tr>
</tbody>
</table>
Expand Down
4 changes: 2 additions & 2 deletions docs/spock-reports/graph.DijkstrasAlgorithmSpec.html
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ <h2>Report for graph.DijkstrasAlgorithmSpec</h2>
</div>
<div class='summary-report'>
<h3>Summary:</h3>
<div class='date-test-ran'>Created on Mon Jan 03 21:16:51 EET 2022 by jegors.cemisovs</div>
<div class='date-test-ran'>Created on Mon Jan 03 21:28:27 EET 2022 by jegors.cemisovs</div>
<table class='summary-table'>
<thead>
<tr>
Expand All @@ -272,7 +272,7 @@ <h3>Summary:</h3>
<td>0</td>
<td>0</td>
<td>100.0%</td>
<td>0.022 seconds</td>
<td>0.023 seconds</td>
</tr>
</tbody>
</table>
Expand Down
4 changes: 2 additions & 2 deletions docs/spock-reports/graph.GraphSpec.html
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ <h2>Report for graph.GraphSpec</h2>
</div>
<div class='summary-report'>
<h3>Summary:</h3>
<div class='date-test-ran'>Created on Mon Jan 03 21:16:51 EET 2022 by jegors.cemisovs</div>
<div class='date-test-ran'>Created on Mon Jan 03 21:28:28 EET 2022 by jegors.cemisovs</div>
<table class='summary-table'>
<thead>
<tr>
Expand All @@ -272,7 +272,7 @@ <h3>Summary:</h3>
<td>0</td>
<td>0</td>
<td>100.0%</td>
<td>0.037 seconds</td>
<td>0.045 seconds</td>
</tr>
</tbody>
</table>
Expand Down
4 changes: 2 additions & 2 deletions docs/spock-reports/graph.SearchAlgorithmSpec.html
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ <h2>Report for graph.SearchAlgorithmSpec</h2>
</div>
<div class='summary-report'>
<h3>Summary:</h3>
<div class='date-test-ran'>Created on Mon Jan 03 21:16:51 EET 2022 by jegors.cemisovs</div>
<div class='date-test-ran'>Created on Mon Jan 03 21:28:28 EET 2022 by jegors.cemisovs</div>
<table class='summary-table'>
<thead>
<tr>
Expand All @@ -272,7 +272,7 @@ <h3>Summary:</h3>
<td>0</td>
<td>0</td>
<td>100.0%</td>
<td>0.003 seconds</td>
<td>0.011 seconds</td>
</tr>
</tbody>
</table>
Expand Down
12 changes: 6 additions & 6 deletions docs/spock-reports/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ <h2>Specification run results</h2>
</div>
<div class='summary-report'>
<h3>Specifications summary:</h3>
<div class='date-test-ran'>Created on Mon Jan 03 21:16:52 EET 2022 by jegors.cemisovs</div>
<div class='date-test-ran'>Created on Mon Jan 03 21:28:28 EET 2022 by jegors.cemisovs</div>
<table class='summary-table'>
<thead>
<tr>
Expand All @@ -111,7 +111,7 @@ <h3>Specifications summary:</h3>
<td>0</td>
<td>0</td>
<td>100.0%</td>
<td>0.131 seconds</td>
<td>0.150 seconds</td>
</tr>
</tbody>
</table>
Expand Down Expand Up @@ -142,7 +142,7 @@ <h3>Specifications:</h3>
<td>0</td>
<td>0</td>
<td>100.0%</td>
<td>0.069 seconds</td>
<td>0.071 seconds</td>
</tr>
<tr>
<td>
Expand All @@ -155,7 +155,7 @@ <h3>Specifications:</h3>
<td>0</td>
<td>0</td>
<td>100.0%</td>
<td>0.022 seconds</td>
<td>0.023 seconds</td>
</tr>
<tr>
<td>
Expand All @@ -168,7 +168,7 @@ <h3>Specifications:</h3>
<td>0</td>
<td>0</td>
<td>100.0%</td>
<td>0.037 seconds</td>
<td>0.045 seconds</td>
</tr>
<tr>
<td>
Expand All @@ -181,7 +181,7 @@ <h3>Specifications:</h3>
<td>0</td>
<td>0</td>
<td>100.0%</td>
<td>0.003 seconds</td>
<td>0.011 seconds</td>
</tr>
</tbody>
</table>
Expand Down
1 change: 0 additions & 1 deletion src/test/groovy/graph/GraphSpec.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import spock.lang.Title
class GraphSpec extends Specification {

def "should return edges for a given node"() {

given: 'a simple graph with three nodes'
def graph = Graph.of([
A: [B: 7, C: 2],
Expand Down