"port" argument must be >= 0 and < 65536

Hello All, Greetings…!

I am building my application with the help of gradle. It fails with the test saying ‘“port” argument must be >= 0 and < 65536’.

what will be the problem and how to resolve it. Can anybody help me

Thanks & Regards, Priyanka

It’s hard to help without Gradle specific knowledge.

Can you explain specifically what you are trying to accomplish with Gradle? Include any configuration details.

basically I am building my project with the help of gradle and i am getting this error so not sure whats cause of the error and solution for the same.

I don’t know Gradle. So you’re going have to help me out here. What exactly are you doing with Gradle? How is Gradle integrated with Ember?

This is likely caused by having multiple ember serve’s running. Likely a bug in a more recent version of ember-cli because I’ve also started noticing it as well.

So how to resolve it?

Gradle is an open source build automation system something similar to maven. With gradle we are compiling our ember server and UI and trying to build application. We will get .jar file as an output.

Thanks & Regrads, Priyanka

Yes, and I know that Gradle uses a DSL on top of Groovy. Can you paste your entire build.gradle here?

This is what I get in build.gradle

apply plugin: “com.kiefer.gradle.embercli” apply plugin: “idea”

idea { module { excludeDirs += file(‘tmp’) excludeDirs += file(‘node_modules’) excludeDirs += file(‘bower_components’) excludeDirs += file(‘dist’) } }

Thanks & Regards, Priyanka

You are required to customize embercli section in you build.gradle where you can specify port argument for running your tests.

embercli {
    testArguments = ["--test-port=7357"]
}

Apart from this, you need to have PhantomJS installed. You can install the same using npm install -g phantomjs

Details on customizing gradle build plugin for embercli can be found here

Hope this helps.