(t *testing.T)
| 535 | } |
| 536 | |
| 537 | func TestDiv(t *testing.T) { |
| 538 | src := `<? $a / $b;` |
| 539 | |
| 540 | expected := &node.Root{ |
| 541 | Position: &position.Position{ |
| 542 | StartLine: 1, |
| 543 | EndLine: 1, |
| 544 | StartPos: 3, |
| 545 | EndPos: 11, |
| 546 | }, |
| 547 | Stmts: []node.Node{ |
| 548 | &stmt.Expression{ |
| 549 | Position: &position.Position{ |
| 550 | StartLine: 1, |
| 551 | EndLine: 1, |
| 552 | StartPos: 3, |
| 553 | EndPos: 11, |
| 554 | }, |
| 555 | Expr: &binary.Div{ |
| 556 | Position: &position.Position{ |
| 557 | StartLine: 1, |
| 558 | EndLine: 1, |
| 559 | StartPos: 3, |
| 560 | EndPos: 10, |
| 561 | }, |
| 562 | Left: &expr.Variable{ |
| 563 | Position: &position.Position{ |
| 564 | StartLine: 1, |
| 565 | EndLine: 1, |
| 566 | StartPos: 3, |
| 567 | EndPos: 5, |
| 568 | }, |
| 569 | VarName: &node.Identifier{ |
| 570 | Position: &position.Position{ |
| 571 | StartLine: 1, |
| 572 | EndLine: 1, |
| 573 | StartPos: 3, |
| 574 | EndPos: 5, |
| 575 | }, |
| 576 | Value: "a", |
| 577 | }, |
| 578 | }, |
| 579 | Right: &expr.Variable{ |
| 580 | Position: &position.Position{ |
| 581 | StartLine: 1, |
| 582 | EndLine: 1, |
| 583 | StartPos: 8, |
| 584 | EndPos: 10, |
| 585 | }, |
| 586 | VarName: &node.Identifier{ |
| 587 | Position: &position.Position{ |
| 588 | StartLine: 1, |
| 589 | EndLine: 1, |
| 590 | StartPos: 8, |
| 591 | EndPos: 10, |
| 592 | }, |
| 593 | Value: "b", |
| 594 | }, |
nothing calls this directly
no test coverage detected
searching dependent graphs…