Comments (2)
Hi @PeaceKeeperOrg,
You can see our UITestBase
example in our blog post
https://envoy.engineering/embedded-web-server-for-ios-ui-testing-8ff3cef513df#.jf4nit18p
You can also see the gist here
https://gist.github.com/fangpenlin/b180cc4a3c7bbe123ee298b03067b6ab
Although it's for UI testing, it won't be any different to just inherit from XCTest
instead in your case.
from ambassador.
Hi @fangpenlin, I tried to follow those guidelines but I cannot make it work properly.
I have create the files you said in the article but still not working as I expected. I have created the "DefaultRouter" file, UITestBase file and MyUITests file in my UI Test folder. Also I have created an Alamofire requets in my ViewController with is the endpoint I want to mock with Ambassador, but the localhost from Ambassador is always "http://[::1]:8080/api/v2/users" and it never returns the correct information.
What can I do to make it work? Do you have a really working example? Because I never found a real working example mocking an endpoint from a ViewController.
Thanks in advance,
Regards.
from ambassador.
Related Issues (20)
- Response body gets cut off HOT 5
- Server returning previous router response on high memory load HOT 2
- Multi-part form upload returns empty data using DataReader HOT 8
- Different response data and status codes HOT 1
- `4.0.4` tagged source has `4.0.3` version in Podspec HOT 1
- Get query string from a request HOT 2
- Running server in the different thread
- Performance issues when running tests on parallel HOT 2
- Similar endpoints HOT 4
- Router an API with parameters
- Router mixing similar routes HOT 2
- Supporting different states of a mocked response HOT 2
- New Release For Embassy
- Individual servers for parallel testing clones HOT 2
- Support many states api responses
- Delay response doesnt work as expected
- Retrieving request Headers through Router
- Providing path to json file instead of content of the json. HOT 1
- Fatal error with xcode 14 with Bad file descriptor
- Fatal error with iOS 16 in TCPSocket
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ambassador.