缺少标识为QUnit的库-G Suite教育帐户 [英] Library with identifier QUnit is missing - G Suite for Education Account

查看:231
本文介绍了缺少标识为QUnit的库-G Suite教育帐户的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在尝试使用QUnit来测试我的代码,但一直收到此错误:缺少带有标识符QUnit的库(也许它已被删除,或者您没有读取权限?)." /p>

我确定我已使用正确的密钥正确安装了它.

我的google帐户是我公司设置的G Suite教育帐户,我有两个不同的教育帐户.两个帐户彼此位于不同的组织单位中.其中之一可以毫无问题地运行QUnit,但我需要它在引发错误的帐户上工作.

我也按照以下步骤将QUnit添加到我的项目中:

  1. 进入图书馆并输入代码"MxL38OxqIK-B73jyDTvCe-OBao7QLBR4j"

  2. 选定的版本4.

  3. 发布为Web应用程序,然后选择测试Web应用程序的最新代码".查看结果.

  4. 然后在新选项卡上显示错误消息.

当我在个人Google帐户"上尝试同样的步骤时,似乎也没有问题.

下面是我的QUnit代码,如果您可以看到我出了问题的地方,或者您应该知道应该更改的任何G Suite设置,那么这将是一个很大的帮助.

function doGet( e ) {
  QUnit.urlParams( e.parameter );
  
  QUnit.config({
    title: "Unit tests for my project" 
  });
  QUnit.load( tests );
  return QUnit.getHtml();
};


function tests() {
  addEqual();
  addNotEqual();
  multiplyEqual();
  multiplyNotEqual();
}


function addEqual() {
  test("Add number to number", function() {
    equal(addNumbers(), 5, 'It worked!');
  });
}

function addNotEqual() {
  test("Add number to number", function() {
    equal(addNumbers(), 8, 'It worked!');
  });
}

function multiplyEqual() {
  test("Multiply Number with a Number", function() {
    equal(multiply(), 6, 'It Worked!');
  });
}

function multiplyNotEqual() {
  test("Multiply Number with a Number", function() {
    notEqual(multiply(), 9, 'It Worked!');
  });
}

解决方案

摘要:

到目前为止,解决此问题的最简单方法是根本不使用库功能,而是直接从库源复制粘贴文件.请注意,所有.gs.html文件都应作为单独的文件包含在您的项目中.解决的其他方法包括删除呼叫脚本项目并在新项目中重新添加每个库的各种版本.在库开发人员方面,它包括保存该库的新版本.

可能的原因:

可能的解决方案:

当前未解决的问题跟踪器:

封闭式跟踪器(用于研究):

相关:

I have been trying to use QUnit to test my code but have been getting this error: "Library with identifier QUnit is missing (perhaps it was deleted, or maybe you don't have read access?)."

I am sure I have installed it correctly with the correct key.

My google account is a G Suite for Education Account that's been set up by my company, I have two different Education accounts with them. Both accounts are in different organisational units from each other. One of them can run QUnit with no issues but I need it to work on the account that is throwing the error.

I took the following steps too add QUnit to my project:

  1. Went onto Libraries and entered the code "MxL38OxqIK-B73jyDTvCe-OBao7QLBR4j"

  2. Selected version 4.

  3. Published as a Web App and then selected "Test web app for your latest code" to view the results.

  4. I am then presented with the error message on a new tab.

When I try these same steps on my Personal Google Account as well there seems to be no issues.

Below is my QUnit code, if you can see where I've went wrong or if there are any G Suite Settings that should be changed that you know of that would be a great help.

function doGet( e ) {
  QUnit.urlParams( e.parameter );
  
  QUnit.config({
    title: "Unit tests for my project" 
  });
  QUnit.load( tests );
  return QUnit.getHtml();
};


function tests() {
  addEqual();
  addNotEqual();
  multiplyEqual();
  multiplyNotEqual();
}


function addEqual() {
  test("Add number to number", function() {
    equal(addNumbers(), 5, 'It worked!');
  });
}

function addNotEqual() {
  test("Add number to number", function() {
    equal(addNumbers(), 8, 'It worked!');
  });
}

function multiplyEqual() {
  test("Multiply Number with a Number", function() {
    equal(multiply(), 6, 'It Worked!');
  });
}

function multiplyNotEqual() {
  test("Multiply Number with a Number", function() {
    notEqual(multiply(), 9, 'It Worked!');
  });
}

解决方案

Summary:

So far, the easiest way to solve the issue is not to use the library feature at all, but directly copy paste files from the library's source. Note that all .gs and .html files should be included as separate files in your project. Other ways to solve includes various versions of deleting the calling script project and re-adding each library in a new project. On the library developer side, it includes saving a new version of the library.

Possible Cause(s):

Possible Solution(s):

Currently Open Issue Trackers:

Closed Trackers(for research):

Related:

这篇关于缺少标识为QUnit的库-G Suite教育帐户的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆