diff --git a/hls-refine-imports-plugin.cabal b/hls-refine-imports-plugin.cabal
--- a/hls-refine-imports-plugin.cabal
+++ b/hls-refine-imports-plugin.cabal
@@ -1,14 +1,19 @@
-cabal-version:      2.2
+cabal-version:      2.4
 name:               hls-refine-imports-plugin
-version:            1.0.0.0
+version:            1.0.0.1
 synopsis:           Refine imports plugin for Haskell Language Server
+description:
+  Please see the README on GitHub at <https://github.com/haskell/haskell-language-server#readme>
 license:            Apache-2.0
 license-file:       LICENSE
 author:             rayshih
 maintainer:         mnf.shih@gmail.com
 category:           Development
 build-type:         Simple
-extra-source-files: LICENSE
+extra-source-files:
+  LICENSE
+  test/testdata/*.hs
+  test/testdata/*.yaml
 
 library
   exposed-modules:    Ide.Plugin.RefineImports
@@ -22,7 +27,7 @@
     , ghcide                       ^>=1.4
     , hls-explicit-imports-plugin  ^>=1.0.0.1
     , hls-graph
-    , hls-plugin-api               ^>=1.1
+    , hls-plugin-api               >=1.1     && <1.3
     , lsp
     , text
     , unordered-containers
diff --git a/test/testdata/A.hs b/test/testdata/A.hs
new file mode 100644
--- /dev/null
+++ b/test/testdata/A.hs
@@ -0,0 +1,7 @@
+module A 
+  ( module B
+  , module C
+  ) where
+
+import B
+import C
diff --git a/test/testdata/B.hs b/test/testdata/B.hs
new file mode 100644
--- /dev/null
+++ b/test/testdata/B.hs
@@ -0,0 +1,7 @@
+module B where 
+
+b1 :: String
+b1 = "b1"
+
+b2 :: String
+b2 = "b2"
diff --git a/test/testdata/C.hs b/test/testdata/C.hs
new file mode 100644
--- /dev/null
+++ b/test/testdata/C.hs
@@ -0,0 +1,4 @@
+module C where
+
+c1 :: String
+c1 = "c1"
diff --git a/test/testdata/D.hs b/test/testdata/D.hs
new file mode 100644
--- /dev/null
+++ b/test/testdata/D.hs
@@ -0,0 +1,7 @@
+module D (module E, module D) where
+
+import E hiding (e1)
+import qualified E
+
+e1 :: String 
+e1 = E.e1 <> " but overrided"
diff --git a/test/testdata/E.hs b/test/testdata/E.hs
new file mode 100644
--- /dev/null
+++ b/test/testdata/E.hs
@@ -0,0 +1,7 @@
+module E where
+
+e1 :: String
+e1 = "e1"
+
+e2 :: String
+e2 = "e2"
diff --git a/test/testdata/F.hs b/test/testdata/F.hs
new file mode 100644
--- /dev/null
+++ b/test/testdata/F.hs
@@ -0,0 +1,7 @@
+module F (module F, module G) where
+
+import G
+
+f1 :: String 
+f1 = "f1"
+
diff --git a/test/testdata/G.hs b/test/testdata/G.hs
new file mode 100644
--- /dev/null
+++ b/test/testdata/G.hs
@@ -0,0 +1,4 @@
+module G where
+
+g1 :: String 
+g1 = "g1"
diff --git a/test/testdata/UsualCase.expected.hs b/test/testdata/UsualCase.expected.hs
new file mode 100644
--- /dev/null
+++ b/test/testdata/UsualCase.expected.hs
@@ -0,0 +1,10 @@
+module Main where
+
+import A
+import E ( e2 )
+import Data.List (intercalate)
+
+main :: IO ()
+main = putStrLn 
+     $ "hello " 
+    <> intercalate ", " [b1, c1, e2]
diff --git a/test/testdata/UsualCase.hs b/test/testdata/UsualCase.hs
new file mode 100644
--- /dev/null
+++ b/test/testdata/UsualCase.hs
@@ -0,0 +1,10 @@
+module Main where
+
+import A
+import D
+import Data.List (intercalate)
+
+main :: IO ()
+main = putStrLn 
+     $ "hello " 
+    <> intercalate ", " [b1, c1, e2]
diff --git a/test/testdata/WithOverride.expected.hs b/test/testdata/WithOverride.expected.hs
new file mode 100644
--- /dev/null
+++ b/test/testdata/WithOverride.expected.hs
@@ -0,0 +1,12 @@
+module Main where
+
+import B ( b1 )
+import C ( c1 )
+import D
+import F
+import Data.List (intercalate)
+
+main :: IO ()
+main = putStrLn 
+     $ "hello " 
+    <> intercalate ", " [b1, c1, e1, f1, g1]
diff --git a/test/testdata/WithOverride.hs b/test/testdata/WithOverride.hs
new file mode 100644
--- /dev/null
+++ b/test/testdata/WithOverride.hs
@@ -0,0 +1,11 @@
+module Main where
+
+import A
+import D
+import F
+import Data.List (intercalate)
+
+main :: IO ()
+main = putStrLn 
+     $ "hello " 
+    <> intercalate ", " [b1, c1, e1, f1, g1]
diff --git a/test/testdata/hie.yaml b/test/testdata/hie.yaml
new file mode 100644
--- /dev/null
+++ b/test/testdata/hie.yaml
@@ -0,0 +1,12 @@
+cradle:
+  direct:
+    arguments:
+    - UsualCase.hs
+    - WithOverride.hs
+    - A.hs
+    - B.hs
+    - C.hs
+    - D.hs
+    - E.hs
+    - F.hs
+    - G.hs
