Skip to content

Commit

Permalink
Fix a few warnings (#1759)
Browse files Browse the repository at this point in the history
  • Loading branch information
jrudolph authored and ktoso committed Jan 29, 2018
1 parent 4351662 commit 829181e
Show file tree
Hide file tree
Showing 13 changed files with 11 additions and 15 deletions.
Expand Up @@ -7,7 +7,7 @@ package akka.http.impl.engine.client
import akka.NotUsed
import akka.annotation.InternalApi
import akka.http.scaladsl.settings.{ ClientConnectionSettings, ParserSettings }
import akka.stream.impl.ConstantFun
import akka.util.ConstantFun

import scala.annotation.tailrec
import scala.concurrent.Promise
Expand Down
Expand Up @@ -10,7 +10,7 @@ import java.io.File
import java.nio.file.Path
import java.lang.{ Iterable JIterable }
import java.util.Optional
import java.util.concurrent.{ CompletionStage, Executor, TimeUnit }
import java.util.concurrent.{ CompletionStage, Executor }

import scala.compat.java8.FutureConverters
import scala.concurrent.duration.FiniteDuration
Expand Down
Expand Up @@ -15,7 +15,7 @@ import scala.collection.immutable
import scala.collection.JavaConverters._
import scala.util.{ Failure, Success, Try }
import akka.event.LoggingAdapter
import akka.stream.impl.ConstantFun
import akka.util.ConstantFun
import akka.stream.Materializer
import akka.stream.javadsl.{ Source JSource }
import akka.stream.scaladsl._
Expand Down
Expand Up @@ -9,7 +9,6 @@ import akka.actor.ActorSystem
import akka.annotation.InternalApi
import akka.stream.scaladsl.Sink
import akka.stream.testkit.TestSubscriber
import akka.testkit.TestKit
import akka.util.ByteString

import scala.annotation.tailrec
Expand Down
Expand Up @@ -16,7 +16,7 @@ import akka.http.scaladsl.model.ws._
import Protocol.Opcode
import akka.testkit._
import akka.stream.OverflowStrategy
import org.scalatest.concurrent.{ Eventually, PatienceConfiguration }
import org.scalatest.concurrent.Eventually

class MessageSpec extends FreeSpec with Matchers with WithMaterializerSpec with Eventually {
import WSTestUtils._
Expand Down
Expand Up @@ -5,12 +5,11 @@
package akka.http.impl.util

import java.io.{ OutputStream, PrintStream }
import java.util.concurrent.atomic.AtomicLong

import akka.actor.ActorSystem
import akka.event.Logging
import akka.event.Logging._
import akka.testkit.{ AkkaSpec, EventFilter, TestEventListener }
import akka.testkit.{ EventFilter, TestEventListener }
import org.scalatest.{ Outcome, SuiteMixin, TestSuite }

/**
Expand Down
Expand Up @@ -6,7 +6,6 @@ package akka.http.scaladsl

import akka.actor.ActorSystem
import akka.event.Logging
import akka.stream.ActorMaterializer
import akka.testkit.{ EventFilter, TestKit, TestProbe }
import com.typesafe.config.{ Config, ConfigFactory }
import org.scalatest.{ Matchers, WordSpec }
Expand Down
Expand Up @@ -5,7 +5,7 @@
package akka.http.scaladsl.testkit

import akka.http.scaladsl.settings.RoutingSettings
import akka.stream.impl.ConstantFun
import akka.util.ConstantFun
import com.typesafe.config.{ Config, ConfigFactory }

import scala.collection.immutable
Expand Down
Expand Up @@ -11,8 +11,7 @@ import akka.http.impl.model.JavaQuery
import akka.http.impl.util.JavaMapping
import akka.http.impl.util.JavaMapping.Implicits._
import akka.http.javadsl.model._
import akka.http.scaladsl.model.{ ContentTypeRange, ContentTypes, FormData SFormData }
import akka.http.scaladsl.model.{ Multipart SMultipart }
import akka.http.scaladsl.model.{ ContentTypeRange, ContentTypes }
import akka.http.scaladsl.unmarshalling
import akka.http.scaladsl.unmarshalling.FromEntityUnmarshaller
import akka.http.scaladsl.unmarshalling.Unmarshaller.{ EnhancedFromEntityUnmarshaller, UnsupportedContentTypeException }
Expand Down
Expand Up @@ -9,7 +9,7 @@ import akka.http.scaladsl.common.EntityStreamingSupport
import akka.http.scaladsl.model._
import akka.http.scaladsl.util.FastFuture
import akka.http.scaladsl.util.FastFuture._
import akka.stream.impl.ConstantFun
import akka.util.ConstantFun
import akka.stream.scaladsl.Source
import akka.util.ByteString

Expand Down
Expand Up @@ -14,7 +14,7 @@ import scala.concurrent.{ ExecutionContextExecutor, Future }
import scala.collection.immutable
import akka.event.LoggingAdapter
import akka.http.scaladsl.model.Uri.Path
import akka.stream.impl.ConstantFun.scalaIdentityFunction
import akka.util.ConstantFun.scalaIdentityFunction
import akka.stream.{ ActorMaterializerHelper, Materializer }
import akka.http.scaladsl.settings.{ ParserSettings, RoutingSettings }
import akka.http.scaladsl.server.util.Tuple
Expand Down
Expand Up @@ -6,7 +6,7 @@ package akka.http.scaladsl.unmarshalling

import akka.http.scaladsl.unmarshalling.Unmarshaller.EitherUnmarshallingException
import akka.http.scaladsl.util.FastFuture
import akka.stream.impl.ConstantFun
import akka.util.ConstantFun

import scala.concurrent.Future
import scala.reflect.ClassTag
Expand Down
Expand Up @@ -75,7 +75,7 @@ class ErrorFormatter(
val ix = error.position.index
if (ix < input.length) {
val chars = mismatchLength(error)
if (chars == 1) sb.append("Invalid input '").append(CharUtils.escape(input charAt ix)).append(''')
if (chars == 1) sb.append("Invalid input '").append(CharUtils.escape(input charAt ix)).append('\'')
else sb.append("Invalid input \"").append(CharUtils.escape(input.sliceString(ix, ix + chars))).append('"')
} else sb.append("Unexpected end of input")
}
Expand Down

0 comments on commit 829181e

Please sign in to comment.