fix: enhance useImport tests with improved structure and error handling
- Introduced a new wrapper function for query client to facilitate testing. - Added comprehensive tests for upload, commit, and cancel operations. - Improved error handling in tests to capture and assert error states. - Enhanced session management and state reset functionality in tests. - Implemented polling behavior tests for import status and preview queries. - Ensured that upload previews are prioritized over status query previews. - Validated cache invalidation and state management after commit and cancel actions.
This commit is contained in:
+14
@@ -0,0 +1,14 @@
|
||||
#!/bin/sh
|
||||
if [ "$1" = "version" ]; then
|
||||
echo "v2.0.0"
|
||||
exit 0
|
||||
fi
|
||||
if [ "$1" = "fmt" ]; then
|
||||
exit 0
|
||||
fi
|
||||
if [ "$1" = "adapt" ]; then
|
||||
# Return a host that conflicts with existing (conflict.example.com)
|
||||
echo "{\"apps\":{\"http\":{\"servers\":{\"srv0\":{\"routes\":[{\"match\":[{\"host\":[\"conflict.example.com\"]}],\"handle\":[{\"handler\":\"reverse_proxy\",\"upstreams\":[{\"dial\":\"192.168.1.100:9000\"}]}]}]}}}}}"
|
||||
exit 0
|
||||
fi
|
||||
exit 1
|
||||
Reference in New Issue
Block a user