Detox mocking: Trouble with Metro Bundler in Github Actions - github-actions

So I've been following the documentation for Detox mocking, and I have successfully gotten it to run locally. But only when I run APP_MOCK=mocked npx react-native start, so this means that when trying to create CI/CD with Github Actions, it starts the Metro bundler and hangs there,
like this.
I've tried adding APP_MOCK=mocked to react-native run-ios/android but it just results in the mocked files not being loaded. My guess is that the APP_MOCK=mocked enviromental variable does not exist in the new terminal that the Metro open.
So my question is this, can I add APP_MOCK=mocked to react-native run-ios and if yes, how? Or is it possible to programmatically open a new terminal in the same directory and then run the APP_MOCK=mocked npx react-native start script?
Thanks in advance!

Related

Heroku cannot detect my node buildpack for app, but when setting buildpack in cli it says the heroku/nodejs is already set up on app?

I have tried deploying app through heroku through cli and through linking git repo, through the git repo I am now getting
! Warning: Multiple default buildpacks reported the ability to handle this app. The first buildpack in the list below will be used.
Detected build packs: Python, Node.js
However, when I try to uninstall python build pack as explained here (https://devcenter.heroku.com/articles/buildpacks) it says it can't be detected. When I try to install Node build pack it says it cannot be detected. But when I press deploy branch it runs the python pack since it is apparently the first build pack in the list.
I have tried making a requirement.txt file as noted in other answers but that took me from error in the post title to the error listed above with multiple packs

how to run dotnet core's standalone program on mac

a rudimentary question, but please let me know.
I want to run the following program which will process and return the result by json when accessed by GET or POST.
FileManagerController.cs
For example, in PHP you just need to place it in the htdocs folder of Apache.
I would like to do the same thing with dot net core mvc.
but I don't know what kind of words to search.
Also, in the near future we would like ruby to work the same way in another project.(In a way that doesn't use a framework such as rails)
So, please tell me how to find out how to run various languages alone on a web server.
You need to make a "project" (file type .csproj) that you can build and run on your machine. Check out the Getting Started with ASP.NET page for instructions to install the SDK and create a new project and run it.
To run your code file above, you can:
$ dotnet new mvc
Copy the above FileManagerController.cs file into the generated Controllers folder.
$ dotnet run
Your app will be running on http://localhost:5000, you can hit your web site using the url /FileManager.

Created jar from JRuby file using warbler. Application exit/goes in a blink when run

I have created a JRuby desktop application. Now I need to create installation file for different platforms(Windows, Linux, Mac).
I have created .jar file using warbler. But when I try to run the .jar, application starts and exit in a blink. It seems application is not crashing as the log says got via java -jar MyApp.jar > log.txt.
Why the application exit, doesn't just stay. Can somebody help me on what I am missing. How I can track the issue?
This answer will help for the issue: JRuby script with Rubeus and Swing exiting once packaged into jar using warble
The workaround described is to put below code in your App's main file
event_thread = nil
SwingUtilities.invokeAndWait { event_thread = java.lang.Thread.currentThread }
event_thread.join

Cordova build error :transformclasseswithdexfordebug

When I try build app I get this error what I do?
I tried re-install node.js and cordova but it didn't work.
Why not use Ionic to build your app via Cloud.
First, run
ionic io init
Create account on Ionic website, put in the details on command live as asked.
Run the below command.
ionic package build android
No need to install anything, files will be built online.

yii2 install, configure and run codeception tests

I'm writing this because yii2 official documentation is still not complete and codeception documentation itself refer to yii2 official docs..:).
I have some questions:
In my yii2 app root there is a directory "tests/codeception", this means that codeception is already installed in my project?
in vendor/yiisoft there is another codeception directory "yii2-codeception" what is it?
the documentation say to create a yii2_basic_tests database and to run a migration, but migration script create only a "migration" table, is it correct?
the integration with yii2 provide some web interface or I must run the tests from console scripts?
Someone can explain me how to install and configure codeception in yii2 basic app step by step?
Thank you
Alessandro
I am doing some like that:
composer global require "codeception/codeception=2.0.*" "codeception/specify=*" "codeception/verify=*"
And next:
ln -s ~/.composer/vendor/bin/codecept /usr/local/bin/codecept
Then I am available to do globally
codecept run
First make sure you read this a couple of times http://www.yiiframework.com/doc-2.0/guide-test-environment-setup.html
Afterwards the actual tests are easy to set up. Make sure you make the codecept command work like it says on the last line of the link above. After you install an Yii app you have to go to the tests folder and run
codecept build
to initialise the tests. Then run
codecept run
to run the actual tests.
You can run
codecept run --coverage-html
to get the code coverage for your project.
I have never got the acceptance testing working with code coverage but I got acceptance working without coverage and unit&functional with coverage.