added another test
diff --git a/test/build/script_compactor_test.dart b/test/build/script_compactor_test.dart
index 69e6949..7ffed81 100644
--- a/test/build/script_compactor_test.dart
+++ b/test/build/script_compactor_test.dart
@@ -238,6 +238,20 @@
     'https://www.dartlang.org/tools/pub/pubspec.html#name.'
   ], StringFormatter.noNewlinesOrSurroundingWhitespace);
 
+  testPhases('package names with double periods are not allowed', phases, {
+    'a..b|web/a.html': '''
+        <!DOCTYPE html><html><head></head><body>
+          <script type="application/dart" src="a.dart"></script>
+        </body></html>''',
+    'a..b|web/a.dart': '''
+        library a.a;
+        main(){}''',
+  }, {}, [
+    'error: Invalid package name `a..b`. Package names should be '
+    'valid dart identifiers, as indicated at '
+    'https://www.dartlang.org/tools/pub/pubspec.html#name.'
+  ], StringFormatter.noNewlinesOrSurroundingWhitespace);
+
   testPhases('package names with internal periods are allowed', phases, {
     'a.b|web/a.html': '''
         <!DOCTYPE html><html><head></head><body>