diff --git a/tests/basic/test_repomap.py b/tests/basic/test_repomap.py
index 2278d4564..ccecbdf12 100644
--- a/tests/basic/test_repomap.py
+++ b/tests/basic/test_repomap.py
@@ -563,12 +563,38 @@ fn main() {
),
"tsx": (
"test.tsx",
- (
- "import React from 'react';\n\nconst Greeting: React.FC<{ name: string }> = ({"
- " name }) => {\n return
Hello, {name}!
;\n};\n\nexport default"
- " Greeting;\n"
- ),
- "Greeting", # Key symbol to check
+ """import React, { useState, useEffect } from 'react';
+
+interface UserProps {
+ name: string;
+ age?: number;
+}
+
+// Component with props interface
+const UserGreeting: React.FC = ({ name, age }) => {
+ const [greeting, setGreeting] = useState('');
+
+ useEffect(() => {
+ setGreeting(`Hello, ${name}${age ? ` (${age})` : ''}!`);
+ }, [name, age]);
+
+ return {greeting}
;
+};
+
+// Custom hook
+function useCounter(initial: number = 0) {
+ const [count, setCount] = useState(initial);
+ const increment = () => setCount(c => c + 1);
+ return { count, increment };
+}
+
+// Constants
+const DEFAULT_NAME = 'World';
+const MAX_AGE = 150;
+
+export { UserGreeting, useCounter, DEFAULT_NAME, MAX_AGE };
+""",
+ "UserGreeting", # Key symbol to check
),
"csharp": (
"test.cs",