           , (err, res) ->
             for file in atom.config.get 'sync-settings.extraFiles'
               expect(res.files[file]).toBeDefined()
+
+      it "don't back up extra files defined in config.extraFiles", ->
+        atom.config.set 'sync-settings.extraFiles', undefined
+        run (cb) ->
+          SyncSettings.backup cb
+        , ->
+          run (cb) =>
+            SyncSettings.createClient().gists.get({id: @gistId}, cb)
+          , (err, res) ->
+            expect(Object.keys(res.files).length).toBe(1)
 
     describe "::restore", ->
       it "updates settings", ->

          , (err, res) ->
            expect(res.files['keymap.cson']).toBeDefined()

      it "back up the user styles", ->
        atom.config.set('sync-settings.syncStyles', true)
        run (cb) ->

          , (err, res) ->
            expect(res.files['init.coffee']).toBeDefined()

      it "don't back up the user init.coffee file", ->
        atom.config.set('sync-settings.syncInit', false)
        run (cb) ->
          SyncSettings.backup cb
        , ->
          run (cb) =>
            SyncSettings.createClient().gists.get({id: @gistId}, cb)
          , (err, res) ->
            expect(res.files['init.coffee']).not.toBeDefined()

      it "back up the user snippets", ->
        atom.config.set('sync-settings.syncSnippets', true)
        run (cb) ->
