anchor.diff:                a * (b + c) = a * b + a * c
   
       ]
  -//////////////////////////////////////////////////////////////////////////////////////////////////////////////
  +///////////////////////////////////////////////////////////////////////////////
       
   [<EntryPoint>]
   let main args =
  
positive.code:                 2 -- 4
                  3 -- 4
              }"
              let g = load_undirected_test_graph
              let v = Visualisation.toDotGraphDescriptionLanguage g
              checkDotLanguage v expected            
  
          testCase "directed graph" <| fun _ ->
              let expected = "digraph {
  
negative.code: let graphTypeTests = 
  
      testList "Graph ADT" [
          testCase "vertex lookup" <| fun _ ->            
              trial {
                  let! g = load_undirected_test_graph
                  let! v1 = Graph.vertexFromId g (VertexId 1)
                  return v1.Identifier
              }
              |> returnOrFail |> should equal (VertexId 1)
  
          testCase "vertex lookup with negative id returns GraphAccessFailure " <| fun _ ->            
              let r = 
                  trial {
                      let! g = load_undirected_test_graph
                      return! Graph.vertexFromId g (VertexId -1)
                  }
              r |> should equal (Bad [GraphAccessFailure (InvalidVertexId (VertexId -1))])
  
          testCase "vertex lookup with out of range id returns GraphAccessFailure " <| fun _ ->
              trial {
                  let! g = load_undirected_test_graph
                  return! Graph.vertexFromId g (VertexId 999)
              }
              |> should equal (Bad [GraphAccessFailure (InvalidVertexId (VertexId 999))])
                  
          testCase "vertices sequence is 1 based" <| fun _ ->
              trial {
                  let! g = load_undirected_test_graph
                  let hasVertexWithIdZero = 
                      Graph.verticesSeq g 
                      |> Array.ofSeq 
                      |> Array.exists (fun vertex -> vertex.Identifier.Id = 0) 
                  return hasVertexWithIdZero
              }            
              |> returnOrFail |> should be False
      ]
  
  [<Tests>]
  let generationTests = 
      
      testList "Graph Generation" [
          testCase "Serialized header parsing" <| fun _ ->
              Generation.extractHeader "1 2" 
              |> returnOrFail |> should equal (1, 2)
  
          testCase "Header parsing returns ParsingFailure wrong number of inputs" <| fun _ ->
              Generation.extractHeader "1 2 3" |> expectOneFailedWith isParsingFailure |> should be True
              
          testCase "Header parsing returns ParsingFailure if cannot parse to numbers" <| fun _ ->
              Generation.extractHeader "a b" |> expectOneFailedWith isParsingFailure |> should be True
  
          testCase "Vertex Id pair parsing" <| fun _ ->
              Generation.extractVertexIdPair "1 2" 
              |> returnOrFail |> should equal (VertexId 1, VertexId 2)
  
          testCase "Vertex Id returns ParsingFailure wrong number of inputs" <| fun _ ->
              Generation.extractVertexIdPair "1 2 3" |> expectOneFailedWith isParsingFailure |> should be True
  
          testCase "Vertex Id pair parsing returns ParsingFailure if cannot parse to numbers" <| fun _ ->
              Generation.extractVertexIdPair "a b" |> expectOneFailedWith isParsingFailure |> should be True
                          
          testCase "read undirected graph works" <| fun _ ->
              let isDirected = false
              trial {
                  let! g = Generation.readGraphFromFile isDirected (test_graph_file "undirected_graph.txt") 
                  g.VerticesCount |> should equal 4
                  g.EdgesCount |> should equal 5
                  g.IsDirected |> should be False
                  let adjacents = 
                      neighbourIdNumbers g >> returnOrFail
                  adjacents 1 |> should equal [2; 4]
                  adjacents 2 |> should equal [1; 3; 4]
                  adjacents 3 |> should equal [2; 4]
                  adjacents 4 |> should equal [1; 2; 3]
                  return ()
              }
              |> returnOrFail
  
          testCase "read directed graph works" <| fun _ ->
              let isDirected = true
              trial {
                  let! g = Generation.readGraphFromFile isDirected (test_graph_file "directed_graph.txt") 
                  g.VerticesCount |> should equal 5
                  g.EdgesCount |> should equal 8
                  g.IsDirected |> should be True
                  let adjacents = 
                      neighbourIdNumbers g >> returnOrFail
                  adjacents 1 |> should equal [2]
                  adjacents 2 |> should equal [5]
                  adjacents 3 |> should equal [1; 4]
                  adjacents 4 |> should equal [3]
                  adjacents 5 |> should equal [1; 3; 4]
              }
              |> returnOrFail            
      ]   
  
  [<Tests>]
  