Skip to content

Commit

Permalink
Collection name space change (#66)
Browse files Browse the repository at this point in the history
  • Loading branch information
JR-Morgan authored Aug 8, 2024
1 parent 6f5f044 commit 78faa71
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/Speckle.Sdk/Models/Collections/Collection.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ namespace Speckle.Sdk.Models.Collections;
/// A <see cref="Collection"/> can be for example a Layer in Rhino/AutoCad, a collection in Blender, or a Category in Revit.
/// The location of each collection in the hierarchy of collections in a commit will be retrieved through commit traversal.
/// </remarks>
[SpeckleType("Speckle.Core.Models.Collection")]
[SpeckleType("Speckle.Core.Models.Collections.Collection")]
[DeprecatedSpeckleType("Speckle.Core.Models.Collection")]
[DeprecatedSpeckleType("Objects.Organization.Collection")]
public class Collection : Base
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,11 @@ public void TraverseWithPath()
var basePaths = collection.TraverseWithPath((obj => obj is not Collection)).ToList();

Assert.That(basePaths.Count, Is.EqualTo(3));
Assert.That(basePaths[0].Item2.speckle_type, Is.EqualTo("Speckle.Core.Models.Collection"));
Assert.That(basePaths[0].Item2.speckle_type, Is.EqualTo("Speckle.Core.Models.Collections.Collection"));
Assert.That(basePaths[0].Item2["name"], Is.EqualTo("collection"));
Assert.That(basePaths[0].Item1, Is.EqualTo(new List<string>()));

Assert.That(basePaths[1].Item2.speckle_type, Is.EqualTo("Speckle.Core.Models.Collection"));
Assert.That(basePaths[1].Item2.speckle_type, Is.EqualTo("Speckle.Core.Models.Collections.Collection"));
Assert.That(basePaths[1].Item2["name"], Is.EqualTo("subCollection"));
Assert.That(basePaths[1].Item1, Is.EqualTo(new List<string>() { "collection" }));

Expand Down

0 comments on commit 78faa71

Please sign in to comment.