MCPcopy Create free account
hub / github.com/z7zmey/php-parser / TestIdentical

Function TestIdentical

node/expr/binary/t_binary_op_test.go:837–910  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

835}
836
837func TestIdentical(t *testing.T) {
838 src := `<? $a === $b;`
839
840 expected := &node.Root{
841 Position: &position.Position{
842 StartLine: 1,
843 EndLine: 1,
844 StartPos: 3,
845 EndPos: 13,
846 },
847 Stmts: []node.Node{
848 &stmt.Expression{
849 Position: &position.Position{
850 StartLine: 1,
851 EndLine: 1,
852 StartPos: 3,
853 EndPos: 13,
854 },
855 Expr: &binary.Identical{
856 Position: &position.Position{
857 StartLine: 1,
858 EndLine: 1,
859 StartPos: 3,
860 EndPos: 12,
861 },
862 Left: &expr.Variable{
863 Position: &position.Position{
864 StartLine: 1,
865 EndLine: 1,
866 StartPos: 3,
867 EndPos: 5,
868 },
869 VarName: &node.Identifier{
870 Position: &position.Position{
871 StartLine: 1,
872 EndLine: 1,
873 StartPos: 3,
874 EndPos: 5,
875 },
876 Value: "a",
877 },
878 },
879 Right: &expr.Variable{
880 Position: &position.Position{
881 StartLine: 1,
882 EndLine: 1,
883 StartPos: 10,
884 EndPos: 12,
885 },
886 VarName: &node.Identifier{
887 Position: &position.Position{
888 StartLine: 1,
889 EndLine: 1,
890 StartPos: 10,
891 EndPos: 12,
892 },
893 Value: "b",
894 },

Callers

nothing calls this directly

Calls 4

ParseMethod · 0.95
GetRootNodeMethod · 0.95
NewParserFunction · 0.92
NewParserFunction · 0.92

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…