File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -1714,6 +1714,22 @@ end
17141714
17151715 # Any operation should immediately convert it:
17161716 @test km ^ - 1 isa Quantity{T,DynamicQuantities. SymbolicDimensions{R}} where {T,R}
1717+
1718+ # Test promotion explicitly for coverage:
1719+ @test promote_type (
1720+ SymbolicDimensionsSingleton{Int16},
1721+ SymbolicDimensionsSingleton{Int32}
1722+ ) === SymbolicDimensions{Int32}
1723+ # ^ Note how we ALWAYS convert to SymbolicDimensions, even
1724+ # if the types are the same.
1725+ @test promote_type (
1726+ SymbolicDimensionsSingleton{Int16},
1727+ SymbolicDimensions{Int32}
1728+ ) === SymbolicDimensions{Int32}
1729+ @test promote_type (
1730+ SymbolicDimensionsSingleton{Int64},
1731+ Dimensions{Int16}
1732+ ) === Dimensions{Int64}
17171733end
17181734
17191735@testset " Test div" begin
You can’t perform that action at this time.
0 commit comments